@samitouri / QOS-React / commits / 4528cddf51

Removes UpdateQueueNode.callbackWasCalled (#8290)

Tracking this isn't necessary.

Andrew Clark committed Nov 15, 2016 at 09:52 UTC 4528cddf518246d2f617e45e81a421031dc97c4e
1 file changed +1 -5
src/renderers/shared/fiber/ReactFiberUpdateQueue.js
+1 -5
@@ -15,7 +15,6 @@
15 type UpdateQueueNode = {
16 partialState: any,
17 callback: ?Function,
18 - callbackWasCalled: boolean,
18 isReplace: boolean,
19 next: ?UpdateQueueNode,
20 };
@@ -31,7 +30,6 @@ exports.createUpdateQueue = function(partialState : mixed) : UpdateQueue {
30 const queue = {
31 partialState,
32 callback: null,
34 - callbackWasCalled: false,
33 isReplace: false,
34 next: null,
35 isForced: false,
@@ -47,7 +45,6 @@ function addToQueue(queue : UpdateQueue, partialState : mixed) : UpdateQueue {
45 const node = {
46 partialState,
47 callback: null,
50 - callbackWasCalled: false,
48 isReplace: false,
49 next: null,
50 };
@@ -74,9 +71,8 @@ exports.callCallbacks = function(queue : UpdateQueue, context : any) : Error | n
71 let firstError = null;
72 while (node) {
73 const callback = node.callback;
77 - if (callback && !node.callbackWasCalled) {
74 + if (callback) {
75 try {
79 - node.callbackWasCalled = true;
76 if (typeof context !== 'undefined') {
77 callback.call(context);
78 } else {