Bump deps w/ eslint (#2302)

* Bump deps w/ eslint

* Additional cleanups

* Additional

* @polkadot/types done

* Additional

* @polkadot/typegen done

* Additional

* @polkadot/rpc-core done

* Additional

* Additional

* Additional

* docs

* @polkadot/api-derive done

* @polkadot/api done

* @polkadot/api-contracts done

* Update tests
This commit is contained in:
Jaco Greeff
2020-05-24 09:24:45 +02:00
committed by GitHub
parent 97cb408f36
commit 47fc4a2b3c
158 changed files with 701 additions and 497 deletions
+3 -3
View File
@@ -4,7 +4,7 @@
import { DeriveCache } from './types';
const mapCache: Map<string, any> = new Map();
const mapCache = new Map<string, any>();
const deriveMapCache: DeriveCache = {
del: (key: string): void => {
@@ -18,7 +18,7 @@ const deriveMapCache: DeriveCache = {
}
},
get: <T = any> (key: string): T | undefined => {
return mapCache.get(key);
return mapCache.get(key) as T;
},
set: (key: string, value: any): void => {
mapCache.set(key, value);
@@ -29,7 +29,7 @@ const deriveNoopCache: DeriveCache = {
del: (): void => undefined,
forEach: () => undefined,
get: (): undefined => undefined,
set: (_: string, value: any): any => value
set: (_: string, value: unknown): unknown => value
};
export { deriveMapCache, deriveNoopCache };