diff options
| author | Gustav Sörnäs <gustav@sornas.net> | 2021-06-08 08:55:53 +0200 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2021-06-08 08:55:53 +0200 |
| commit | 63516f245afa117b9017c338c0cb42d64fab4a4f (patch) | |
| tree | 0adbbc531fd74c8551b6d5f8ae1b1d5dce30f590 /mumlib | |
| parent | be76c2aa51733a0cf495e92659fbcbe527f41149 (diff) | |
| parent | 4cf73b2d08bd50b38ca610ca67cad01958ca8577 (diff) | |
| download | mum-63516f245afa117b9017c338c0cb42d64fab4a4f.tar.gz | |
Merge pull request #95 from mum-rs/message-timestamps
Store and print timestamp with messages
Diffstat (limited to 'mumlib')
| -rw-r--r-- | mumlib/Cargo.toml | 2 | ||||
| -rw-r--r-- | mumlib/src/command.rs | 3 |
2 files changed, 3 insertions, 2 deletions
diff --git a/mumlib/Cargo.toml b/mumlib/Cargo.toml index 5c9d4e1..5ec9365 100644 --- a/mumlib/Cargo.toml +++ b/mumlib/Cargo.toml @@ -13,7 +13,7 @@ readme = "../README.md" [dependencies] colored = "2" -chrono = "0.4" +chrono = { version = "0.4", features = [ "serde" ] } dirs = "3" fern = "0.6" log = "0.4" diff --git a/mumlib/src/command.rs b/mumlib/src/command.rs index 351d7f6..27ca60c 100644 --- a/mumlib/src/command.rs +++ b/mumlib/src/command.rs @@ -1,5 +1,6 @@ use crate::state::{Channel, Server}; +use chrono::NaiveDateTime; use serde::{Deserialize, Serialize}; #[derive(Clone, Debug, Deserialize, Serialize)] @@ -63,7 +64,7 @@ pub enum CommandResponse { server_state: Server, }, PastMessage { - message: (String, String), + message: (NaiveDateTime, String, String), }, } |
