Add isHistoric flags to RPC with hash params (#2535)

* Add isHistoric flags to RPC with hash params

* Update packages/types/src/interfaces/chain/definitions.ts

* Apply suggestions from code review

* Transparently swap registry on RPC layer

* Simplify (& linting fixes)

* Cleanups

* CHANGELOG
This commit is contained in:
Jaco Greeff
2020-08-30 12:12:18 +02:00
committed by GitHub
parent a83980b213
commit 7876bb9ced
10 changed files with 81 additions and 24 deletions
@@ -27,6 +27,7 @@ export default {
{
name: 'hash',
type: 'BlockHash',
isHistoric: true,
isOptional: true
}
],
@@ -23,6 +23,7 @@ export default {
{
name: 'at',
type: 'Hash',
isHistoric: true,
isOptional: true
}
],
@@ -42,6 +43,7 @@ export default {
{
name: 'at',
type: 'Hash',
isHistoric: true,
isOptional: true
}
],
@@ -61,6 +63,7 @@ export default {
{
name: 'at',
type: 'Hash',
isHistoric: true,
isOptional: true
}
],
@@ -80,6 +83,7 @@ export default {
{
name: 'at',
type: 'Hash',
isHistoric: true,
isOptional: true
}
],
@@ -19,6 +19,7 @@ export default {
{
name: 'at',
type: 'BlockHash',
isHistoric: true,
isOptional: true
}
],
@@ -38,6 +39,7 @@ export default {
{
name: 'at',
type: 'BlockHash',
isHistoric: true,
isOptional: true
}
],
@@ -53,6 +55,7 @@ export default {
{
name: 'at',
type: 'BlockHash',
isHistoric: true,
isOptional: true
}
],
@@ -19,6 +19,7 @@ export default {
{
name: 'at',
type: 'BlockHash',
isHistoric: true,
isOptional: true
}
],
@@ -24,6 +24,7 @@ export default {
{
name: 'at',
type: 'BlockHash',
isHistoric: true,
isOptional: true
}
],
@@ -39,6 +40,7 @@ export default {
{
name: 'at',
type: 'BlockHash',
isHistoric: true,
isOptional: true
}
],
@@ -54,6 +56,7 @@ export default {
{
name: 'at',
type: 'BlockHash',
isHistoric: true,
isOptional: true
}
],
@@ -79,6 +82,7 @@ export default {
{
name: 'at',
type: 'BlockHash',
isHistoric: true,
isOptional: true
}
],
@@ -95,6 +99,7 @@ export default {
{
name: 'at',
type: 'BlockHash',
isHistoric: true,
isOptional: true
}
],
@@ -111,6 +116,7 @@ export default {
{
name: 'at',
type: 'BlockHash',
isHistoric: true,
isOptional: true
}
],
@@ -127,6 +133,7 @@ export default {
{
name: 'at',
type: 'BlockHash',
isHistoric: true,
isOptional: true
}
],
@@ -154,6 +161,7 @@ export default {
{
name: 'at',
type: 'BlockHash',
isHistoric: true,
isOptional: true
}
],
@@ -181,6 +189,7 @@ export default {
{
name: 'at',
type: 'BlockHash',
isHistoric: true,
isOptional: true
}
],
@@ -208,6 +217,7 @@ export default {
{
name: 'at',
type: 'BlockHash',
isHistoric: true,
isOptional: true
}
],
@@ -235,6 +245,7 @@ export default {
{
name: 'at',
type: 'BlockHash',
isHistoric: true,
isOptional: true
}
],
@@ -292,6 +303,7 @@ export default {
{
name: 'at',
type: 'BlockHash',
isHistoric: true,
isOptional: true
}
],
@@ -307,6 +319,7 @@ export default {
{
name: 'at',
type: 'BlockHash',
isHistoric: true,
isOptional: true
}
],
@@ -31,6 +31,7 @@ export default {
{
name: 'at',
type: 'BlockHash',
isHistoric: true,
isOptional: true
}
],
+1
View File
@@ -13,6 +13,7 @@ export type DefinitionTypeStruct = Record<string, DefinitionTypeType> | { _alias
export type DefinitionType = string | DefinitionTypeEnum | DefinitionTypeSet | DefinitionTypeStruct;
export interface DefinitionRpcParam {
isHistoric?: boolean;
isOptional?: boolean;
name: string;
type: DefinitionTypeType;