X-Git-Url: http://git.onelab.eu/?a=blobdiff_plain;f=plugins%2Flists%2Fsimplelist.js;h=46534cefbf4cc3910e37a6de4dbff77baf3b950b;hb=d36cb74e23439c1d0982a3a004c0bff486ca910f;hp=e883759a808f969bfd27d96a76e0d1aa12e963ff;hpb=d5dbeb380b9205233540eaf6dfbd21db15129816;p=myslice.git diff --git a/plugins/lists/simplelist.js b/plugins/lists/simplelist.js index e883759a..46534cef 100644 --- a/plugins/lists/simplelist.js +++ b/plugins/lists/simplelist.js @@ -27,15 +27,12 @@ init : function( options ) { return this.each(function(){ var $this = $(this), data = $this.data('SimpleList'); - // If the plugin hasn't been initialized yet - if ( ! data ) { - /* Subscribe to query updates */ - var channel='/results/' + options.query_uuid + '/changed'; - /* passing $this as 2nd arg: callbacks will retrieve $this as e.data */ - $.subscribe(channel, $this, update_plugin); - if (debug) window.console.log('subscribing to ' + channel); - $this.data('SimpleList', options); - } + /* Subscribe to query updates */ + var channel='/results/' + options.query_uuid + '/changed'; + /* passing $this as 2nd arg: callbacks will retrieve $this as e.data */ + $.subscribe(channel, $this, update_plugin); + if (debug) window.console.log('subscribing to ' + channel); + $this.data('SimpleList', options); }); }, destroy : function( ) {