Skip to content

Commit

Permalink
Refactor import of lodash merge function
Browse files Browse the repository at this point in the history
  • Loading branch information
WojtekBoman committed Oct 31, 2023
1 parent 059306c commit d2122bc
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/libs/actions/PersistedRequests.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import {merge} from 'lodash';
import isEqual from 'lodash/isEqual';
import lodashMerge from 'lodash/merge';
import Onyx, {OnyxUpdate} from 'react-native-onyx';
import ONYXKEYS from '@src/ONYXKEYS';
import {Request} from '@src/types/onyx';
Expand Down Expand Up @@ -41,7 +41,7 @@ function createUpdatedRequest(oldRequest: Request, newRequest: Request): Request
* In order to create updated request, properties: data, failureData, successData and optimisticData have to be merged
*/
const updatedRequest = {
data: merge({...oldRequest.data}, newRequest.data),
data: lodashMerge({...oldRequest.data}, newRequest.data),
failureData: mergeOnyxUpdateData(oldRequest.failureData, newRequest.failureData),
successData: mergeOnyxUpdateData(oldRequest.successData, newRequest.successData),
...newRequest,
Expand Down

0 comments on commit d2122bc

Please sign in to comment.