@@ -5,7 +5,7 @@ import waitForPromisesToResolve from '../utils/waitForPromisesToResolve';
55import OnyxUtils from '../../lib/OnyxUtils' ;
66import type OnyxCache from '../../lib/OnyxCache' ;
77import StorageMock from '../../lib/storage' ;
8- import type { DeepRecord , OnyxCollection , OnyxUpdate } from '../../lib/types' ;
8+ import type { GenericDeepRecord , OnyxCollection , OnyxUpdate } from '../../lib/types' ;
99import type GenericCollection from '../utils/GenericCollection' ;
1010import type { Connection } from '../../lib/OnyxConnectionManager' ;
1111
@@ -858,7 +858,6 @@ describe('Onyx', () => {
858858 // When we pass it to Onyx.update
859859 // @ts -expect-error This is an invalid call to Onyx.update
860860 Onyx . update ( data ) ;
861- // eslint-disable-next-line @typescript-eslint/no-explicit-any
862861 } catch ( error ) {
863862 if ( error instanceof Error ) {
864863 // Then we should expect the error message below
@@ -875,7 +874,6 @@ describe('Onyx', () => {
875874 // When we pass it to Onyx.update
876875 // @ts -expect-error This is an invalid call to Onyx.update
877876 Onyx . update ( data ) ;
878- // eslint-disable-next-line @typescript-eslint/no-explicit-any
879877 } catch ( error ) {
880878 if ( error instanceof Error ) {
881879 // Then we should expect the error message below
@@ -1757,8 +1755,7 @@ describe('Onyx', () => {
17571755 } ) ;
17581756
17591757 it ( 'replacing old object after null merge' , async ( ) => {
1760- // eslint-disable-next-line @typescript-eslint/no-explicit-any
1761- const entry1 : DeepRecord < string , any > = {
1758+ const entry1 : GenericDeepRecord = {
17621759 sub_entry1 : {
17631760 id : 'sub_entry1' ,
17641761 someKey : 'someValue' ,
@@ -1799,8 +1796,7 @@ describe('Onyx', () => {
17991796 } ) ;
18001797
18011798 it ( 'setting new object after null merge' , async ( ) => {
1802- // eslint-disable-next-line @typescript-eslint/no-explicit-any
1803- const entry1 : DeepRecord < string , any > = {
1799+ const entry1 : GenericDeepRecord = {
18041800 sub_entry1 : {
18051801 id : 'sub_entry1' ,
18061802 someKey : 'someValue' ,
@@ -1872,8 +1868,7 @@ describe('Onyx', () => {
18721868 } ) ;
18731869
18741870 it ( 'setting new object after null merge of a primitive property' , async ( ) => {
1875- // eslint-disable-next-line @typescript-eslint/no-explicit-any
1876- const entry1 : DeepRecord < string , any > = {
1871+ const entry1 : GenericDeepRecord = {
18771872 sub_entry1 : {
18781873 id : 'sub_entry1' ,
18791874 someKey : 'someValue' ,
@@ -1933,8 +1928,7 @@ describe('Onyx', () => {
19331928 } ) ;
19341929
19351930 it ( 'replacing nested object during updates' , async ( ) => {
1936- // eslint-disable-next-line @typescript-eslint/no-explicit-any
1937- const entry1 : DeepRecord < string , any > | undefined = {
1931+ const entry1 : GenericDeepRecord | undefined = {
19381932 id : 'entry1' ,
19391933 someKey : 'someValue' ,
19401934 } ;
@@ -1945,8 +1939,7 @@ describe('Onyx', () => {
19451939 } ,
19461940 } ) ;
19471941
1948- // eslint-disable-next-line @typescript-eslint/no-explicit-any
1949- let entry1ExpectedResult = lodashCloneDeep ( entry1 ) as DeepRecord < string , any > | undefined ;
1942+ let entry1ExpectedResult = lodashCloneDeep ( entry1 ) as GenericDeepRecord | undefined ;
19501943 const queuedUpdates : OnyxUpdate [ ] = [ ] ;
19511944
19521945 queuedUpdates . push ( {
@@ -2002,15 +1995,14 @@ describe('Onyx', () => {
20021995
20031996 describe ( 'mergeCollection' , ( ) => {
20041997 it ( 'replacing old object after null merge' , async ( ) => {
2005- // eslint-disable-next-line @typescript-eslint/no-explicit-any
2006- const entry1 : DeepRecord < string , any > = {
1998+ const entry1 : GenericDeepRecord = {
20071999 sub_entry1 : {
20082000 id : 'sub_entry1' ,
20092001 someKey : 'someValue' ,
20102002 } ,
20112003 } ;
2012- // eslint-disable-next-line @typescript-eslint/no-explicit-any
2013- const entry2 : DeepRecord < string , any > = {
2004+
2005+ const entry2 : GenericDeepRecord = {
20142006 sub_entry2 : {
20152007 id : 'sub_entry2' ,
20162008 someKey : 'someValue' ,
@@ -2132,8 +2124,7 @@ describe('Onyx', () => {
21322124 } ) ;
21332125
21342126 it ( 'replacing old object after null merge' , async ( ) => {
2135- // eslint-disable-next-line @typescript-eslint/no-explicit-any
2136- const entry1 : DeepRecord < string , any > = {
2127+ const entry1 : GenericDeepRecord = {
21372128 sub_entry1 : {
21382129 id : 'sub_entry1' ,
21392130 someKey : 'someValue' ,
@@ -2165,8 +2156,7 @@ describe('Onyx', () => {
21652156 } ) ;
21662157
21672158 it ( 'setting new object after null merge' , async ( ) => {
2168- // eslint-disable-next-line @typescript-eslint/no-explicit-any
2169- const entry1 : DeepRecord < string , any > = {
2159+ const entry1 : GenericDeepRecord = {
21702160 sub_entry1 : {
21712161 id : 'sub_entry1' ,
21722162 someKey : 'someValue' ,
@@ -2225,8 +2215,7 @@ describe('Onyx', () => {
22252215 } ) ;
22262216
22272217 it ( 'setting new object after null merge of a primitive property' , async ( ) => {
2228- // eslint-disable-next-line @typescript-eslint/no-explicit-any
2229- const entry1 : DeepRecord < string , any > = {
2218+ const entry1 : GenericDeepRecord = {
22302219 sub_entry1 : {
22312220 id : 'sub_entry1' ,
22322221 someKey : 'someValue' ,
0 commit comments