Transaction permissioning (#6441)
This commit is contained in:
committed by
Gav Wood
parent
2df61d0a8c
commit
eed0e8b03a
@@ -80,6 +80,8 @@ pub enum TransactionError {
|
||||
CodeBanned,
|
||||
/// Invalid chain ID given.
|
||||
InvalidChainId,
|
||||
/// Not enough permissions given by permission contract.
|
||||
NotAllowed,
|
||||
}
|
||||
|
||||
impl fmt::Display for TransactionError {
|
||||
@@ -104,6 +106,7 @@ impl fmt::Display for TransactionError {
|
||||
RecipientBanned => "Recipient is temporarily banned.".into(),
|
||||
CodeBanned => "Contract code is temporarily banned.".into(),
|
||||
InvalidChainId => "Transaction of this chain ID is not allowed on this chain.".into(),
|
||||
NotAllowed => "Sender does not have permissions to execute this type of transction".into(),
|
||||
};
|
||||
|
||||
f.write_fmt(format_args!("Transaction error ({})", msg))
|
||||
|
||||
Reference in New Issue
Block a user