Skip to content

Commit

Permalink
Merge pull request #35165 from Expensify/ionatan_logoldformat
Browse files Browse the repository at this point in the history
Log if we received push event in old format
  • Loading branch information
danieldoglas authored Jan 25, 2024
2 parents d68ab1a + 2ee6e1a commit 9c32b8f
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/libs/actions/User.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ import type {OnyxEntry} from 'react-native-onyx/lib/types';
import type {ValueOf} from 'type-fest';
import * as API from '@libs/API';
import * as ErrorUtils from '@libs/ErrorUtils';
import Log from '@libs/Log';
import Navigation from '@libs/Navigation/Navigation';
import * as SequentialQueue from '@libs/Network/SequentialQueue';
import * as Pusher from '@libs/Pusher/pusher';
Expand Down Expand Up @@ -490,6 +491,7 @@ function subscribeToUserEvents() {
// - The data is an object, containing updateIDs from the server and an array of onyx updates (this array is the same format as the original format above)
// Example: {lastUpdateID: 1, previousUpdateID: 0, updates: [{onyxMethod: 'whatever', key: 'foo', value: 'bar'}]}
if (Array.isArray(pushJSON)) {
Log.warn('Received pusher event with array format');
pushJSON.forEach((multipleEvent) => {
PusherUtils.triggerMultiEventHandler(multipleEvent.eventType, multipleEvent.data);
});
Expand Down

0 comments on commit 9c32b8f

Please sign in to comment.