Replace Data/U8a with un-aliassed Raw (#1656)
* Replace Data with un-aliassed U8a * Export U8a * Explicitly add U8a to the registry * U8a -> Raw
This commit is contained in:
@@ -4,10 +4,10 @@
|
||||
|
||||
import { Codec, Registry, TypeDefInfo, TypeDef } from '@polkadot/types/types';
|
||||
|
||||
import { Data, Option, createClass } from '@polkadot/types';
|
||||
import { Option, Raw, createClass } from '@polkadot/types';
|
||||
import { createTypeUnsafe } from '@polkadot/types/codec';
|
||||
|
||||
export function formatData (registry: Registry, data: Data, { info, type }: TypeDef): Codec {
|
||||
export function formatData (registry: Registry, data: Raw, { info, type }: TypeDef): Codec {
|
||||
if (info === TypeDefInfo.Option) {
|
||||
return new Option(
|
||||
registry,
|
||||
|
||||
Reference in New Issue
Block a user