style: various small cleanups
This commit is contained in:
parent
999068bdd9
commit
f240413e2a
|
@ -1,6 +1,7 @@
|
|||
/target
|
||||
/examples
|
||||
|
||||
/.idea
|
||||
relays
|
||||
keys
|
||||
*.html
|
|
@ -1,4 +1,3 @@
|
|||
use std::io::{stdin, stdout, Write};
|
||||
use std::ops::Sub;
|
||||
|
||||
use chrono::{DateTime, Local, TimeDelta, TimeZone, Utc};
|
||||
|
|
|
@ -546,6 +546,7 @@ async fn main() -> Result<()> {
|
|||
let (label, times) = tasks.times_tracked();
|
||||
println!("{}\n{}", label.italic(), times.rev().take(15).join("\n"));
|
||||
}
|
||||
// TODO show history from author / pubkey
|
||||
} else {
|
||||
let (label, mut times) = tasks.times_tracked();
|
||||
println!("{}\n{}", label.italic(), times.join("\n"));
|
||||
|
@ -559,7 +560,7 @@ async fn main() -> Result<()> {
|
|||
Some(arg) => {
|
||||
if parse_tracking_stamp(arg).map(|stamp| tasks.track_at(stamp, None)).is_none() {
|
||||
// So the error message is not covered up
|
||||
continue
|
||||
continue;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -396,7 +396,7 @@ impl Tasks {
|
|||
let mut tracking_stamp: Option<Timestamp> = None;
|
||||
for elem in
|
||||
timestamps(self.history.get(&self.sender.pubkey()).into_iter().flatten(), &vec![t.get_id()])
|
||||
.map(|(e, o)| e) {
|
||||
.map(|(e, _)| e) {
|
||||
if tracking_stamp.is_some() && elem > now {
|
||||
break;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue