aboutsummaryrefslogtreecommitdiffstats
path: root/src/plugins/remind/mod.rs
diff options
context:
space:
mode:
authorJokler <jokler.contact@gmail.com>2019-12-07 20:06:20 +0100
committerJokler <jokler.contact@gmail.com>2019-12-07 20:06:20 +0100
commitc7ea1433942bee14be096f39c67136801039263f (patch)
treee960cf8dfc9814cadffb2e1eeb31bc01211b0e8a /src/plugins/remind/mod.rs
parent22a3fcec1ec96451012614265e2653ab5f251df1 (diff)
downloadfrippy-c7ea1433942bee14be096f39c67136801039263f.tar.gz
frippy-c7ea1433942bee14be096f39c67136801039263f.zip
Run cargo fmt on all files
Diffstat (limited to 'src/plugins/remind/mod.rs')
-rw-r--r--src/plugins/remind/mod.rs6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/plugins/remind/mod.rs b/src/plugins/remind/mod.rs
index 1e464b4..b03aebc 100644
--- a/src/plugins/remind/mod.rs
+++ b/src/plugins/remind/mod.rs
@@ -140,7 +140,8 @@ impl<T: Database + 'static, C: FrippyClient> Remind<T, C> {
debug!("New event: {:?}", event);
- Ok(self.events
+ Ok(self
+ .events
.write()
.insert_event(&event)
.map(|id| format!("Created reminder with id {} at {} UTC", id, time))?)
@@ -168,7 +169,8 @@ impl<T: Database + 'static, C: FrippyClient> Remind<T, C> {
.remove(0)
.parse::<i64>()
.context(ErrorKind::Parsing)?;
- let event = self.events
+ let event = self
+ .events
.read()
.get_event(id)
.context(ErrorKind::NotFound)?;