Skip to content

Commit e7e3232

Browse files
committed
Correct returning an object with functions
returned functions now return value after operation
1 parent 746991a commit e7e3232

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

javascript.markdown

+2-2
Original file line numberDiff line numberDiff line change
@@ -1169,11 +1169,11 @@ function Num (value) {
11691169
return {
11701170
add: function (x) {
11711171
value += x;
1172-
return x;
1172+
return value;
11731173
},
11741174
multiply: function (x) {
11751175
value *= x;
1176-
return x;
1176+
return value;
11771177
};
11781178
};
11791179
}

0 commit comments

Comments
 (0)