mirror of https://github.com/zkat/miette.git
fix(error): use the positional way to format docs url
This commit is contained in:
parent
84f820477d
commit
2450afce9e
|
|
@ -40,7 +40,8 @@ impl Diagnostic for MietteError {
|
||||||
fn url<'a>(&'a self) -> Option<Box<dyn fmt::Display + 'a>> {
|
fn url<'a>(&'a self) -> Option<Box<dyn fmt::Display + 'a>> {
|
||||||
let crate_version = env!("CARGO_PKG_VERSION");
|
let crate_version = env!("CARGO_PKG_VERSION");
|
||||||
Some(Box::new(format!(
|
Some(Box::new(format!(
|
||||||
"https://docs.rs/miette/{crate_version}/miette/enum.MietteError.html"
|
"https://docs.rs/miette/{}/miette/enum.MietteError.html",
|
||||||
|
crate_version,
|
||||||
)))
|
)))
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue