summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMatthias Beyer <mail@beyermatthias.de>2016-09-05 00:39:43 +0200
committerMatthias Beyer <mail@beyermatthias.de>2016-09-05 09:21:06 +0200
commit07d4c45b3f21f07416f3d19bde122f11095467b4 (patch)
treefc8c75a33444757484fa8d8ccb27ec069b23ea68
parent24c73325f34e7ac60f26c14a4ee9f2005e4648d2 (diff)
Refactor long line for more readability
-rw-r--r--libimagtodo/src/task.rs5
1 files changed, 2 insertions, 3 deletions
diff --git a/libimagtodo/src/task.rs b/libimagtodo/src/task.rs
index d15d9dea..6b3dc990 100644
--- a/libimagtodo/src/task.rs
+++ b/libimagtodo/src/task.rs
@@ -207,9 +207,8 @@ impl<'a> IntoTask<'a> for TTask {
.and_then(|mut fle| {
{
let mut hdr = fle.get_header_mut();
- if try!(hdr.read("todo").map_err_into(TodoErrorKind::StoreError))
- .is_none()
- {
+ let read = hdr.read("todo").map_err_into(TodoErrorKind::StoreError);
+ if try!(read).is_none() {
try!(hdr
.set("todo", Value::Table(BTreeMap::new()))
.map_err_into(TodoErrorKind::StoreError));