chore (backend-rs): use sea_orm::prelude

This commit is contained in:
naskya 2024-06-03 08:20:39 +09:00
parent fe2fa315f3
commit 98d7eac51b
No known key found for this signature in database
GPG key ID: 712D413B3A9FED5C
4 changed files with 4 additions and 4 deletions

View file

@ -3,7 +3,7 @@
use crate::database::db_conn;
use crate::model::entity::attestation_challenge;
use chrono::{Duration, Utc};
use sea_orm::{ColumnTrait, DbErr, EntityTrait, QueryFilter};
use sea_orm::prelude::*;
/// Delete all entries in the [attestation_challenge] table created at more than 5 minutes ago
#[crate::export]

View file

@ -2,7 +2,7 @@ use crate::config::CONFIG;
use crate::database::{cache, db_conn};
use crate::federation::acct::Acct;
use crate::model::entity::{antenna, blocking, following, note, sea_orm_active_enums::*};
use sea_orm::{ColumnTrait, DbErr, EntityTrait, QueryFilter, QuerySelect};
use sea_orm::{prelude::*, QuerySelect};
#[derive(thiserror::Error, Debug)]
pub enum AntennaCheckError {

View file

@ -6,7 +6,7 @@ use crate::service::antenna::check_hit::{check_hit_antenna, AntennaCheckError};
use crate::service::stream;
use crate::util::id::{get_timestamp, InvalidIdError};
use redis::{streams::StreamMaxlen, AsyncCommands, RedisError};
use sea_orm::{DbErr, EntityTrait};
use sea_orm::prelude::*;
#[derive(thiserror::Error, Debug)]
pub enum Error {

View file

@ -1,7 +1,7 @@
use crate::database::db_conn;
use crate::model::entity::note_watching;
use crate::util::id::gen_id;
use sea_orm::{ActiveValue, ColumnTrait, DbErr, EntityTrait, ModelTrait, QueryFilter};
use sea_orm::{prelude::*, ActiveValue};
#[crate::export]
pub async fn watch_note(