diff options
author | Joan Lledó <jlledom@member.fsf.org> | 2023-09-16 11:34:25 +0200 |
---|---|---|
committer | Joan Lledó <jlledom@member.fsf.org> | 2023-09-30 13:14:45 +0200 |
commit | 5ff42c0a2d7944fd4bbfb424dd0fa05ced266469 (patch) | |
tree | 7045b3a8ea3b30637a43cf4f873e5bde03a59397 /src/database.rs | |
parent | 549803558d22b36ac6ac178722f2a8cc0548531e (diff) | |
download | Furtherance-5ff42c0a2d7944fd4bbfb424dd0fa05ced266469.tar.zst |
Implement ToString trait for Task
Diffstat (limited to 'src/database.rs')
-rw-r--r-- | src/database.rs | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/database.rs b/src/database.rs index 6c558fe..f422d23 100644 --- a/src/database.rs +++ b/src/database.rs @@ -38,6 +38,12 @@ pub struct Task { pub tags: String, } +impl ToString for Task { + fn to_string(&self) -> String { + format!("{} #{}", self.task_name, self.tags) + } +} + #[derive( Debug, Clone, |