Only memomize via instanceId (#2572)
* Add memoizee instanceId * Gotcha. * linitng
This commit is contained in:
@@ -62,8 +62,8 @@ function queryBabe (api: ApiInterfaceRx): Observable<DeriveSessionInfo> {
|
||||
/**
|
||||
* @description Retrieves all the session and era query and calculates specific values on it as the length of the session and eras
|
||||
*/
|
||||
export function info (api: ApiInterfaceRx): () => Observable<DeriveSessionInfo> {
|
||||
return memo((): Observable<DeriveSessionInfo> =>
|
||||
export function info (instanceId: string, api: ApiInterfaceRx): () => Observable<DeriveSessionInfo> {
|
||||
return memo(instanceId, (): Observable<DeriveSessionInfo> =>
|
||||
api.consts.babe
|
||||
? queryBabe(api)
|
||||
: queryAura(api)
|
||||
|
||||
Reference in New Issue
Block a user