Detect session.validators for derive extraction (#1562)

* Detect session.validators for derive extraction

* Add comment

* Indexed extraction without session
This commit is contained in:
Jaco Greeff
2019-11-10 12:25:34 +01:00
committed by GitHub
parent 06418913e5
commit 3c47c3fdc3
3 changed files with 24 additions and 13 deletions
+1 -1
View File
@@ -25,7 +25,7 @@ export function overview (api: ApiInterfaceRx): () => Observable<DerivedStakingO
combineLatest([
of({ currentElected, currentEra, currentIndex, validators, validatorCount }),
// this will change on a per block basis, keep it innermost (and it needs eraIndex)
api.query.staking.currentEraPointsEarned
api.query.staking?.currentEraPointsEarned
? api.query.staking.currentEraPointsEarned<EraPoints>(currentEra)
: of(createType('EraPoints'))
])