build/min/transistor-backbone.js in transistor-0.1.6 vs build/min/transistor-backbone.js in transistor-0.1.7

- old
+ new

@@ -1 +1 @@ -if(window.Transistor===undefined){window.Transistor={}}(function(i){var o=(function(){return function(k){var e,m,f,p,b,d,g,n;e=k.channel;m=k.radio;f=k.control;p=(function(){return{}}());b=new Backbone.Collection();d={add:b.add,remove:b.remove,reset:b.reset,set:b.set};g={add:function(a){f.insert(e,a)},remove:function(a){f.remove(e,a.id)},set:function(a){f.set(e,a)}};g.reset=g.set;(function(h){var l=true,j=function(c){h[c]=(function(a){return function(){if(l){if(!f){throw"BackboneCollection is not mutable by user.";}else{g[a].apply(g,arguments)}}else{return d[a].apply(b,arguments)}}}(c))};d.asPublic=function(a){l=false;a();l=true};j('add');j('remove');j('reset');j('set')}(b));n=i.Binder({set:function(h){d.asPublic(function(){var c=_.map(h,function(a){return new Backbone.Model(a)});b.set(c)})},insert:function(a){d.asPublic(function(){b.add(new Backbone.Model(a))})},update:function(c,h){d.asPublic(function(){var a=b.get(c);a.clear({silent:true});a.set(h)})},remove:function(c){d.asPublic(function(){var a=b.get(c);b.remove(a)})}});m.tune(e,n);return b}}());if(i.Backbone===undefined){i.Backbone={}}i.Backbone.Collection=o}(window.Transistor)); +if(window.Transistor===undefined){window.Transistor={}}(function(i){var p=(function(){return function(j){var k,e,n,f,q,b,d,g,o;k=j.backbone;e=j.channel;n=j.radio;f=j.control;q=(function(){return{}}());b=new k.Collection();d={add:b.add,remove:b.remove,reset:b.reset,set:b.set};g={add:function(a){f.insert(e,a)},remove:function(a){f.remove(e,a.id)},set:function(a){f.set(e,a)}};g.reset=g.set;(function(h){var m=true,l=function(c){h[c]=(function(a){return function(){if(m){if(!f){throw"BackboneCollection is not mutable by user.";}else{g[a].apply(g,arguments)}}else{return d[a].apply(b,arguments)}}}(c))};d.asPublic=function(a){m=false;a();m=true};l('add');l('remove');l('reset');l('set')}(b));o=i.Binder({set:function(h){d.asPublic(function(){var c=_.map(h,function(a){return new k.Model(a)});b.set(c)})},insert:function(a){d.asPublic(function(){b.add(new k.Model(a))})},update:function(c,h){d.asPublic(function(){var a=b.get(c);a.clear({silent:true});a.set(h)})},remove:function(c){d.asPublic(function(){var a=b.get(c);b.remove(a)})}});n.tune(e,o);return b}}());if(i.Backbone===undefined){i.Backbone={}}i.Backbone.Collection=p}(window.Transistor)); \ No newline at end of file