summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMatthias Beyer <mail@beyermatthias.de>2019-11-10 11:05:50 +0100
committerMatthias Beyer <mail@beyermatthias.de>2019-12-22 02:03:35 +0100
commit06dd85bc28d0e81e6b1d4b89c5f2df3af25c2a60 (patch)
treede3f64a5308868d884595a02868f9f3b576aee70
parent7e39a39899151d3fb228907d9691f8479a025a2f (diff)
Use Default implementation for constructing
Signed-off-by: Matthias Beyer <mail@beyermatthias.de>
-rw-r--r--bin/domain/imag-todo/src/lib.rs7
1 files changed, 2 insertions, 5 deletions
diff --git a/bin/domain/imag-todo/src/lib.rs b/bin/domain/imag-todo/src/lib.rs
index 9f22c749..96ff913f 100644
--- a/bin/domain/imag-todo/src/lib.rs
+++ b/bin/domain/imag-todo/src/lib.rs
@@ -147,7 +147,7 @@ impl ImagApplication for ImagTodo {
/// The blacklist is checked first, followed by the whitelist.
/// In case the whitelist is empty, the StatusMatcher works with a
/// blacklist-only approach.
-#[derive(Debug)]
+#[derive(Debug, Default)]
pub struct StatusMatcher {
is: Vec<Status>,
is_not: Vec<Status>,
@@ -155,10 +155,7 @@ pub struct StatusMatcher {
impl StatusMatcher {
pub fn new() -> Self {
- StatusMatcher {
- is: Vec::new(),
- is_not: Vec::new(),
- }
+ StatusMatcher { ..Default::default() }
}
pub fn is(mut self, s: Status) -> Self {