pub enum ToEventError {
InvalidSignature(FromHexError),
InvalidEventType {
type: String,
},
ParseFailed,
VerifySignatureFailed,
}
Expand description
Errors that can occur when converting a GithubWebhook
into an Event
.
Variants§
InvalidSignature(FromHexError)
The X-Hub-Signature-256
header is invalid — it couldn’t be decoded.
InvalidEventType
When parsing the X-Github-Event
header, into an EventType
, it fails.
ParseFailed
When parsing the payload into an Event
, it fails.
VerifySignatureFailed
When verifying the signature, it fails.
Trait Implementations§
Source§impl Debug for ToEventError
impl Debug for ToEventError
Source§impl Display for ToEventError
impl Display for ToEventError
Source§impl Error for ToEventError
impl Error for ToEventError
Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
Returns the lower-level source of this error, if any. Read more
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
👎Deprecated since 1.42.0: use the Display impl or to_string()
Source§impl From<FromHexError> for ToEventError
impl From<FromHexError> for ToEventError
Source§fn from(source: FromHexError) -> Self
fn from(source: FromHexError) -> Self
Converts to this type from the input type.
Auto Trait Implementations§
impl Freeze for ToEventError
impl RefUnwindSafe for ToEventError
impl Send for ToEventError
impl Sync for ToEventError
impl Unpin for ToEventError
impl UnwindSafe for ToEventError
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more