mirror of
https://git.asonix.dog/asonix/http-signature-normalization.git
synced 2024-11-22 01:11:00 +00:00
actix: immediately stringify spantrace
This commit is contained in:
parent
3e2639670e
commit
356c801dac
2 changed files with 4 additions and 4 deletions
|
@ -51,14 +51,14 @@ pub struct VerifyMiddleware<T, S>(S, bool, T);
|
||||||
#[error("Error verifying digest")]
|
#[error("Error verifying digest")]
|
||||||
#[doc(hidden)]
|
#[doc(hidden)]
|
||||||
pub struct VerifyError {
|
pub struct VerifyError {
|
||||||
context: SpanTrace,
|
context: String,
|
||||||
kind: VerifyErrorKind,
|
kind: VerifyErrorKind,
|
||||||
}
|
}
|
||||||
|
|
||||||
impl VerifyError {
|
impl VerifyError {
|
||||||
fn new(span: &Span, kind: VerifyErrorKind) -> Self {
|
fn new(span: &Span, kind: VerifyErrorKind) -> Self {
|
||||||
span.in_scope(|| VerifyError {
|
span.in_scope(|| VerifyError {
|
||||||
context: SpanTrace::capture(),
|
context: SpanTrace::capture().to_string(),
|
||||||
kind,
|
kind,
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
|
@ -75,7 +75,7 @@ impl std::fmt::Display for HeaderKind {
|
||||||
#[derive(Clone)]
|
#[derive(Clone)]
|
||||||
#[doc(hidden)]
|
#[doc(hidden)]
|
||||||
pub struct VerifyError {
|
pub struct VerifyError {
|
||||||
context: SpanTrace,
|
context: String,
|
||||||
kind: VerifyErrorKind,
|
kind: VerifyErrorKind,
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -125,7 +125,7 @@ enum VerifyErrorKind {
|
||||||
impl VerifyError {
|
impl VerifyError {
|
||||||
fn new(span: &Span, kind: VerifyErrorKind) -> Self {
|
fn new(span: &Span, kind: VerifyErrorKind) -> Self {
|
||||||
span.in_scope(|| VerifyError {
|
span.in_scope(|| VerifyError {
|
||||||
context: SpanTrace::capture(),
|
context: SpanTrace::capture().to_string(),
|
||||||
kind,
|
kind,
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue