Skip to content

Commit

Permalink
feat: output serialization powered by the SDK (#7601)
Browse files Browse the repository at this point in the history
* feat: Output serialization powered by the SDK

* fix

---------

Co-authored-by: Begoña Álvarez de la Cruz <[email protected]>
  • Loading branch information
marc2332 and begonaalvarezd authored Oct 23, 2023
1 parent dc91bbc commit 2b617ca
Show file tree
Hide file tree
Showing 6 changed files with 18 additions and 350 deletions.
1 change: 1 addition & 0 deletions packages/shared/lib/core/layer-2/utils/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -11,3 +11,4 @@ export * from './parseLayer2MetadataForTransferV1'
export * from './parseLayer2MetadataForTransferV2'
export * from './parseLayer2MetadataForTransfer'
export * from './specialNativeTokenAmountEncoding'
export * from './outputHexBytes'
6 changes: 6 additions & 0 deletions packages/shared/lib/core/layer-2/utils/outputHexBytes.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
import { api } from '@core/profile-manager'
import { HexEncodedString, Output } from '@iota/sdk/out/types'

export function outputHexBytes(output: Output): Promise<HexEncodedString> {
return api.outputHexBytes(output)
}
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { WalletOptions, CreateAccountPayload, TransactionId, OutputId } from '@iota/sdk/out/types'
import { AliasId, Client, FoundryId, NftId } from '@iota/sdk'
import { AliasId, Client, FoundryId, HexEncodedString, NftId, Output } from '@iota/sdk'
import { IAuth } from '@core/network'
import { INodeInfoResponse } from '@core/network/interfaces'

Expand Down Expand Up @@ -36,4 +36,5 @@ export interface IApi {
aliasIdToBech32(aliasId: string, bech32Hrp: string): string
nftIdToBech32(nftId: string, bech32Hrp: string): string
computeOutputId(id: TransactionId, index: number): Promise<OutputId>
outputHexBytes(output: Output): Promise<HexEncodedString>
}
1 change: 0 additions & 1 deletion packages/shared/lib/core/utils/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@ export * from './number'
export * from './object'
export * from './os'
export * from './random'
export * from './serializeOutput'
export * from './sort'
export * from './store'
export * from './string'
Expand Down
343 changes: 0 additions & 343 deletions packages/shared/lib/core/utils/serializeOutput.ts

This file was deleted.

Loading

0 comments on commit 2b617ca

Please sign in to comment.