Modify ↓
Ticket #6253 (closed bug: invalid)
$.proxy incorrectly passes $.proxy arguments to proxied function
| Reported by: | originofstorms | Owned by: | |
|---|---|---|---|
| Priority: | undecided | Milestone: | |
| Component: | core | Version: | 1.4.2 |
| Keywords: | proxy | Cc: | |
| Blocking: | Blocked by: |
Description
I believe theres a problem with $.proxy. If you call
$.proxy(object, "method")()
object.method is passed the arguments passed to $.proxy... effectively
object.method(object, "method");
A quick look at the $.proxy source reveals the following:
proxy: function( fn, proxy, thisObject ) {
// ... elided ...
proxy = function() {
return fn.apply( thisObject || this, arguments );
};
// ... elided ...
return proxy;
}
Is there a reason for arguments to be passed on through?
Oddly, this causes problems on FF 3.6.2, but not Chromium 5.0.344.0.
Change History
Please follow the bug reporting guidlines and use jsFiddle when providing test cases and demonstrations instead of pasting the code in the ticket.
Note: See
TracTickets for help on using
tickets.

Resetting milestone to future.