feat: implement take errors
All checks were successful
continuous-integration/drone/push Build is passing
All checks were successful
continuous-integration/drone/push Build is passing
Signed-off-by: kjuulh <contact@kjuulh.io>
This commit is contained in:
2
Cargo.lock
generated
2
Cargo.lock
generated
@@ -222,7 +222,7 @@ dependencies = [
|
|||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
name = "notmad"
|
name = "notmad"
|
||||||
version = "0.8.1"
|
version = "0.9.0"
|
||||||
dependencies = [
|
dependencies = [
|
||||||
"anyhow",
|
"anyhow",
|
||||||
"async-trait",
|
"async-trait",
|
||||||
|
|||||||
@@ -166,6 +166,10 @@ impl AggregateError {
|
|||||||
pub fn get_errors(&self) -> &[MadError] {
|
pub fn get_errors(&self) -> &[MadError] {
|
||||||
&self.errors
|
&self.errors
|
||||||
}
|
}
|
||||||
|
|
||||||
|
pub fn take_errors(self) -> Vec<MadError> {
|
||||||
|
self.errors
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
impl Display for AggregateError {
|
impl Display for AggregateError {
|
||||||
|
|||||||
Reference in New Issue
Block a user