Use BN in-place operators as appropriate (#2381)

* Use BN in-place operators as appropriate

* CHANGELOG
This commit is contained in:
Jaco Greeff
2020-06-23 14:02:54 +02:00
committed by GitHub
parent d2be79132c
commit e5c2c6a228
7 changed files with 34 additions and 33 deletions
@@ -18,7 +18,7 @@ export function nextElected (api: ApiInterfaceRx): () => Observable<AccountId[]>
// only populate for next era in the last session, so track both here - entries are not
// subscriptions, so we need a trigger - currentIndex acts as that trigger to refresh
switchMap(({ currentEra }) => api.query.staking.erasStakers.keys(currentEra)),
map((keys) => keys.map((key): AccountId => key.args[1] as AccountId))
map((keys) => keys.map((key) => key.args[1] as AccountId))
)
: api.query.staking.currentElected<AccountId[]>()
);