Always call callback in component context

This brings these other call sites in line with line 67 of ReactUpdates.js:

callbacks[j].call(component);
This commit is contained in:
Ben Alpert committed 2014-01-13 08:59:48 -08:00
1 parent ad6a982cd0
commit 1825f30353
2 files changed
+2 -2

No files matched your search

+1 -1
View File
@@ -318,7 +318,7 @@ var ReactMount = {
container,
shouldReuseMarkup
);
callback && callback();
callback && callback.call(component);
return component;
},
+1 -1
View File
@@ -102,7 +102,7 @@ function enqueueUpdate(component, callback) {
if (!batchingStrategy.isBatchingUpdates) {
component.performUpdateIfNecessary();
callback && callback();
callback && callback.call(component);
return;
}