Skip to content

Commit

Permalink
Adjusted MooTools helper to fix option handling
Browse files Browse the repository at this point in the history
The original $extend method would permanently change the
Downloadify.defaultOptions with the options that were supposed
to override on a per call basis. Using $merge fixes this issue.
  • Loading branch information
Doug Neiner authored and Doug Neiner committed Jan 23, 2010
1 parent 5268bd3 commit 652377f
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
2 changes: 1 addition & 1 deletion js/downloadify.min.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

5 changes: 3 additions & 2 deletions src/downloadify.js
Original file line number Diff line number Diff line change
Expand Up @@ -205,8 +205,9 @@ if(typeof(jQuery) != "undefined"){
if(typeof(MooTools) != 'undefined'){
Element.implement({
downloadify: function(options) {
options = $extend(Downloadify.defaultOptions,options);
options = $merge(Downloadify.defaultOptions,options);
return this.store('Downloadify',Downloadify.create(this,options));
}
});
};
};

0 comments on commit 652377f

Please sign in to comment.