#[non_exhaustive]pub enum OrgsError {
Show 15 variants
NotFound(String),
Forbidden(String),
UnknownRole(String),
InvalidName,
InvalidEmail(String),
TooLong {
field: &'static str,
max: usize,
},
LastOwner,
AlreadyMember(String),
InvitationGone,
InvitationForSomeoneElse,
EmailUnverified,
MailNotConfigured,
Mail(String),
Config(String),
Db(DbError),
}Expand description
What an orgs entry point can fail with.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
NotFound(String)
No such organization, no such member, or the caller is not a member. One variant on purpose: a caller who is not in an organization must not be able to tell it from one that does not exist.
Forbidden(String)
The caller is a member, but their role does not permit this.
UnknownRole(String)
The role is not one the venture configured.
InvalidName
The organization’s name was empty.
InvalidEmail(String)
The address to invite is not an address.
TooLong
A field was longer than the module accepts.
LastOwner
The change would leave the organization with no owner.
AlreadyMember(String)
The account is already a member.
InvitationGone
The invitation is unknown, lapsed or already spent.
InvitationForSomeoneElse
The invitation was issued to a different address.
EmailUnverified
The credential proved no address, so no invitation can be matched.
MailNotConfigured
The deployment has no mailer, or the mailer has no verified domain.
Mail(String)
The provider refused the invitation message.
Config(String)
The module is misconfigured.
Db(DbError)
A database failure.
Implementations§
Trait Implementations§
Source§impl Error for OrgsError
impl Error for OrgsError
Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
use the Display impl or to_string()