Closed
Bug 534776
Opened 15 years ago
Closed 15 years ago
jetpack pageMods callback is executed twice
Categories
(Mozilla Labs :: Jetpack Prototype, defect)
Tracking
(Not tracked)
RESOLVED
DUPLICATE
of bug 543526
People
(Reporter: endico, Unassigned)
Details
I've written a Jetpack feature that adds yelp reviews to search results on opentable.com, however reviews are getting added twice because the pageMods callback is executed twice. ddahl looked this over and thought my code was correct so apparently something is wrong with Jetpack.
1. install feature from http://www.tafoni.net/yelpify/
2. open a tab for about:jetpack and open the debugger
3. In a second tab go to opentable.com and search for restaurants in san francisco (e.g. http://www.opentable.com/opentables-new.aspx?iid=&t=reg&n=32,34,36,35,227,49,916,1382,4418,693,38,2951,4235,40,41,780,42,3287,674,44,641,45,640,3029,&f=82&q=&mn=5&m=4&p=2&d=1/5/2010%207:00:00%20PM)
4. The entry for each restaurant should have a line added to it with an image showing the number of stars plus a sentence linking to yelp. Instead, each restaurant gets two of these entries.
5. Also, the debug console shows two of these lines which indicates that the callback has been called twice: "Yelpify version 0.2 begin"
Using firefox 3.5.5
Jetpack pulled from trunk Nov 29 17:13. The add-ons manager identifies this as Jetpack 0.6.3.
Comment 1•15 years ago
|
||
opentable.com contains an iframe that matches the pageMod, causing it to fire again. google.com does the same.
Reporter | ||
Comment 2•15 years ago
|
||
Morgan has a patch here
https://bugzilla.mozilla.org/show_bug.cgi?id=535001
Comment 3•15 years ago
|
||
I'm seeing this on a page that doesn't have any iframes or frames.
Comment 4•15 years ago
|
||
heh, ignore my last comment. Turns out a Jetpack written by someone else that I had enabled on the page was indeed creating an iframe that I didn't know about.
Updated•15 years ago
|
Status: NEW → RESOLVED
Closed: 15 years ago
Resolution: --- → DUPLICATE
You need to log in
before you can comment on or make changes to this bug.
Description
•