diff --git a/packages/rpc-core/src/index.ts b/packages/rpc-core/src/index.ts index a3d9aae98e..2dd2811935 100644 --- a/packages/rpc-core/src/index.ts +++ b/packages/rpc-core/src/index.ts @@ -336,7 +336,11 @@ export default class Rpc implements RpcInterface { throw error; } } else if (rpc.type === 'StorageChangeSet') { - return this._formatStorageSet(params[0] as Vec, result.changes); + const keys = params[0] as Vec; + + return keys + ? this._formatStorageSet(keys, result.changes) + : this.registry.createType('StorageChangeSet', result); } else if (rpc.type === 'Vec') { const mapped = result.map(({ block, changes }: { block: string; changes: [string, string | null][] }): [Hash, Codec[]] => [ this.registry.createType('Hash', block),