Store room times as epoch time
Resets migrations because nobody except me is using cove anyways and this is easier than keeping backwards compatibility.
This commit is contained in:
parent
cbe2b2e10e
commit
b57c70dd01
3 changed files with 13 additions and 18 deletions
|
|
@ -86,7 +86,7 @@ impl EuphVault {
|
|||
&self.room
|
||||
}
|
||||
|
||||
pub fn join(&self, time: OffsetDateTime) {
|
||||
pub fn join(&self, time: Time) {
|
||||
let request = EuphRequest::Join {
|
||||
room: self.room.clone(),
|
||||
time,
|
||||
|
|
@ -221,7 +221,7 @@ pub(super) enum EuphRequest {
|
|||
},
|
||||
Join {
|
||||
room: String,
|
||||
time: OffsetDateTime,
|
||||
time: Time,
|
||||
},
|
||||
Delete {
|
||||
room: String,
|
||||
|
|
@ -382,7 +382,7 @@ impl EuphRequest {
|
|||
Ok(())
|
||||
}
|
||||
|
||||
fn join(conn: &mut Connection, room: String, time: OffsetDateTime) -> rusqlite::Result<()> {
|
||||
fn join(conn: &mut Connection, room: String, time: Time) -> rusqlite::Result<()> {
|
||||
conn.execute(
|
||||
"
|
||||
INSERT INTO euph_rooms (room, first_joined, last_joined)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue