UniversalDot / universal-dot-front-end

An API + React based template for building Substrate Front Ends
The Unlicense
1 stars 0 forks source link

Decoding error message in front-end #20

Closed stojanov-igor closed 2 years ago

stojanov-igor commented 2 years ago

A DispatchError will refer to a pallet and a member of the pallet's Error enum by index:

DispatchError: {"module":{"index":123,"error":456}}

For polkadot-js, you can retrieve more information about the error via the event and the findMetaError API.

See Stack-overflow for more details: https://substrate.stackexchange.com/questions/947/whats-a-convenient-way-to-look-up-a-dispatcherror-in-polkadot-js

stojanov-igor commented 2 years ago

Has been implemented