Cater for new/old contracts_call results (#2810)

* Cater for new/old contracts_call results

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

* Allow RPC layer to output JSON

* Typing for json outputs

* Convert results

* RPC compat mapping

* Ensure RPC .json is exposed

* Remove compat layer

* Old error detection

* Map to unknown

* Update packages/rpc-core/src/index.ts

* linting
This commit is contained in:
Jaco Greeff
2020-10-31 11:18:58 +01:00
committed by GitHub
parent 2a0e481710
commit e855d5a9d4
11 changed files with 189 additions and 60 deletions
@@ -3,6 +3,7 @@
import Handlebars from 'handlebars';
import Json from '@polkadot/types/codec/Json';
import Raw from '@polkadot/types/codec/Raw';
import { TypeRegistry } from '@polkadot/types/create';
import * as defaultDefinitions from '@polkadot/types/interfaces/definitions';
@@ -13,6 +14,7 @@ import { ModuleTypes } from '../util/imports';
const primitiveClasses = {
...defaultPrimitives,
Json,
Raw
};