summaryrefslogtreecommitdiff
path: root/src/repo/channel.rs
diff options
context:
space:
mode:
authorOwen Jacobson <owen@grimoire.ca>2024-10-02 00:41:25 -0400
committerOwen Jacobson <owen@grimoire.ca>2024-10-02 00:41:38 -0400
commit357116366c1307bedaac6a3dfe9c5ed8e0e0c210 (patch)
treed701378187d8b0f99d524991925e8348c6cab0d6 /src/repo/channel.rs
parentf878f0b5eaa44e8ee8d67cbfd706926ff2119113 (diff)
First pass on reorganizing the backend.
This is primarily renames and repackagings.
Diffstat (limited to 'src/repo/channel.rs')
-rw-r--r--src/repo/channel.rs15
1 files changed, 2 insertions, 13 deletions
diff --git a/src/repo/channel.rs b/src/repo/channel.rs
index 9f1d930..18cd81f 100644
--- a/src/repo/channel.rs
+++ b/src/repo/channel.rs
@@ -1,10 +1,9 @@
use sqlx::{sqlite::Sqlite, SqliteConnection, Transaction};
-use super::sequence::Sequence;
use crate::{
- channel::Id,
+ channel::{Channel, Id},
clock::DateTime,
- events::types::{self},
+ event::{types, Sequence},
};
pub trait Provider {
@@ -19,16 +18,6 @@ impl<'c> Provider for Transaction<'c, Sqlite> {
pub struct Channels<'t>(&'t mut SqliteConnection);
-#[derive(Clone, Debug, Eq, PartialEq, serde::Serialize)]
-pub struct Channel {
- pub id: Id,
- pub name: String,
- #[serde(skip)]
- pub created_at: DateTime,
- #[serde(skip)]
- pub created_sequence: Sequence,
-}
-
impl<'c> Channels<'c> {
pub async fn create(
&mut self,