Skip to content

Commit

Permalink
Creating uninstall method #22
Browse files Browse the repository at this point in the history
  • Loading branch information
danielalves committed Mar 9, 2015
1 parent 387e775 commit 87f2d29
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions src/jquery.silver_track.js
Original file line number Diff line number Diff line change
Expand Up @@ -155,6 +155,15 @@
return this;
},

uninstall: function(plugin) {
var pluginIndex = this.plugins.indexOf(plugin);
if (pluginIndex != -1 ) {
this._callFunction(plugin, "onUninstall");
this.plugins.splice(pluginIndex, 1);
}
return this;
},

reloadItems: function() {
this._items = null;
},
Expand Down

0 comments on commit 87f2d29

Please sign in to comment.