pub fn dispatch_error_to_invalid(error: DispatchError) -> InvalidTransaction
Expand description

convert a DispatchError to a custom InvalidTransaction with the inner code being the error number.