-
Notifications
You must be signed in to change notification settings - Fork 142
Closed
Description
What:
When using js-stellar-base and js-stellar-sdk to manage assets, the method contractId() always returns an error.
Why
By looking at the source code, we can see the method expects an argument that is not present in the exported type.
-
Method:
Line 111 in cf370f4
contractId(networkPassphrase) { -
Exported type:
https://github.com/stellar/js-stellar-base/blob/cf370f4e627e2b0e296ceceaebd0164dede396bd/types/index.d.ts#L82C3-L82C13
Forcing typescript to ignore the error and providing the network passphrase as an argument overcomes the issue. It is necessary to update the type to reflect the need for an argument.
Metadata
Metadata
Assignees
Labels
No labels