Skip to content

Commit 24312ff

Browse files
committed
adds a reasonlog
1 parent f456b02 commit 24312ff

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

settable/settable.js

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -56,14 +56,15 @@ canReflect.assignMap(SettableObservable.prototype, {
5656
log: log,
5757
constructor: SettableObservable,
5858
handler: function(newVal) {
59-
var old = this._value;
59+
var old = this._value, reasonLog;
6060
this._value = newVal;
6161

6262
//!steal-remove-start
6363
if (process.env.NODE_ENV !== 'production') {
6464
if (typeof this._log === "function") {
6565
this._log(old, newVal);
6666
}
67+
reasonLog = [canReflect.getName(this),"set to", newVal, "from", old];
6768
}
6869
//!steal-remove-end
6970

@@ -72,9 +73,8 @@ canReflect.assignMap(SettableObservable.prototype, {
7273
this.handlers.getNode([]),
7374
this,
7475
[newVal, old],
75-
function() {
76-
return {};
77-
}
76+
null,
77+
reasonLog
7878
);
7979
},
8080
onBound: function() {

0 commit comments

Comments
 (0)