diff --git a/src/Client.js b/src/Client.js index 5dac29720..997c95f58 100644 --- a/src/Client.js +++ b/src/Client.js @@ -294,23 +294,20 @@ export default class Client extends EventEmitter { }), ); } - } else { - const apiCallbacks = this.broadcastCallbacks.get(params.api); - if (!apiCallbacks) { - return; - } + } + const apiCallbacks = this.broadcastCallbacks.get(params.api); + if (!apiCallbacks) { + return; + } - const methodCallbacks: ?Set = apiCallbacks.get( - params.method, - ); - if (methodCallbacks) { - for (const callback of methodCallbacks) { - callback(params.params); - } + const methodCallbacks: ?Set = apiCallbacks.get(params.method); + if (methodCallbacks) { + for (const callback of methodCallbacks) { + callback(params.params); } } } - return; + return; // method === 'execute' } if (this.sdkVersion < 1) { diff --git a/src/plugins/fresco/index.js b/src/plugins/fresco/index.js index 4f15cd5f4..a2527892f 100644 --- a/src/plugins/fresco/index.js +++ b/src/plugins/fresco/index.js @@ -271,6 +271,7 @@ export default class extends FlipperPlugin { debugLog('init()'); this.updateCaches('init'); this.client.subscribe('events', (event: ImageEvent) => { + debugLog('Received events', event); const {surfaceList} = this.props.persistedState; const {attribution} = event; if (attribution instanceof Array && attribution.length > 0) {