Bug Tracker

Opened 9 years ago

Closed 9 years ago

Last modified 8 years ago

#8478 closed bug (invalid)

ie7 "unexpected propriety or method" error

Reported by: anonymous Owned by: anonymous
Priority: undecided Milestone: 1.next
Component: ajax Version: 1.5.1
Keywords: Cc:
Blocked by: Blocking:

Description

I use jquery 1.5.1, it works without any error in Chrome 9, Safari 3, firfox 3.6 but I have an error with ie7 when I have ajax call:

"unexpected propriety or method on line 871"

It seems to come from the "finally" statement.

Code: try {

while( callbacks[ 0 ] ) {

callbacks.shift().apply( context, args );

}

} finally {

fired = [ context, args ]; firing = 0;

}

Change History (5)

comment:1 Changed 9 years ago by anonymous

Sorry the last code I posted came from jquery 1.5.1 rc1 version, the code for jquery 1.5.1 is: (the error occur for both version)

try {

while( callbacks[ 0 ] ) {

callbacks.shift().apply( context, args );

}

} We have to add a catch block for IE prior to 8 or else the finally block will never get executed catch (e) {

throw e;

} finally {

fired = [ context, args ]; firing = 0;

}

comment:2 Changed 9 years ago by Rick Waldron

Component: unfiledajax
Owner: set to anonymous
Status: newpending

Thanks for taking the time to contribute to the jQuery project! Please provide a reduced jsFiddle test case to help us assess your ticket!

Additionally, test against the jQuery 0 GIT version to ensure the issue still exists.

comment:3 Changed 9 years ago by jaubourg

Resolution: invalid
Status: pendingclosed

It's most probably an exception thrown into one of your callbacks. The browser simply notifies it at the wrong place because of the catch/rethrow which has been removed in trunk.

comment:4 Changed 9 years ago by pedro@…

i am experiencing the same error... hard to give reproduce code right now.

Updating to 1.5.2 causes the following to happen:

http://img861.imageshack.us/g/bugu.jpg/

You should check this out, IMO. My code is perfectly working AFAIK.

comment:5 Changed 9 years ago by anonymous

was caused by this code earlier in the code.

Object.prototype.count = function () {

var count = 0;

for(var prop in this) {

if(this.hasOwnProperty(prop))

count = count + 1;

} return count;

}

Closed it is

Note: See TracTickets for help on using tickets.