Skip to content

Commit 1fe0204

Browse files
author
Vlad Balin
committed
removed f-functions
Not needed with ES6
1 parent c26adb9 commit 1fe0204

File tree

2 files changed

+2
-20
lines changed

2 files changed

+2
-20
lines changed

src/main.js

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -38,19 +38,10 @@ var ModelProto = Nested.Model.prototype,
3838
LinkAttr = Link.Attr;
3939

4040
ModelProto.lget = function( name ){ return new LinkAttr( this, name ); };
41-
ModelProto.fset = function( a, b, c ){
42-
var self = this;
43-
return function(){ self.set( a, b, c ); }
44-
};
4541

4642
var CollectionProto = Nested.Collection.prototype,
4743
LinkHas = Link.CollectionHas;
4844

4945
CollectionProto.lhas = function( model ){
5046
return new LinkHas( this, model );
5147
};
52-
53-
CollectionProto.ftoggle = function( model, next ){
54-
var self = this;
55-
return function(){ self.toggle( model, next ); }
56-
};

src/valuelink.js

Lines changed: 2 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -4,11 +4,7 @@ var Value = exports.Value = Object.extend( {
44
value : void 0,
55
requestChange : function( val ){ throw new ReferenceError(); },
66

7-
set : function( val ){ this.requestChange( val ); },
8-
fset : function( val ){
9-
var link = this;
10-
return function(){ link.requestChange( val ); }
11-
}
7+
set : function( val ){ this.requestChange( val ); }
128
} );
139

1410
exports.Attr = Value.extend( {
@@ -30,12 +26,7 @@ exports.Attr = Value.extend( {
3026
} );
3127

3228
var Bool = exports.Bool = Value.extend( {
33-
toggle : function(){ this.requestChange( !this.value ); },
34-
35-
ftoggle : function(){
36-
var link = this;
37-
return function(){ link.requestChange( !link.value ) };
38-
}
29+
toggle : function(){ this.requestChange( !this.value ); }
3930
} );
4031

4132
var ValueEql = exports.ValueEql = Bool.extend( {

0 commit comments

Comments
 (0)