Skip to content

Commit ef231d9

Browse files
committed
Bump sea-orm
1 parent c346632 commit ef231d9

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

src/db.rs

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -14,8 +14,8 @@ use chrono::{DateTime, Utc};
1414
use regex::Regex;
1515
use sea_orm::{
1616
ActiveModelTrait, ConnectOptions, ConnectionTrait, Database, DatabaseBackend,
17-
DatabaseConnection, DbBackend, DbConn, DbErr, EntityTrait, ExprTrait, IntoActiveModel,
18-
Statement,
17+
DatabaseConnection, DatabaseConnectionType, DbBackend, DbConn, DbErr, EntityTrait, ExprTrait,
18+
IntoActiveModel, Statement,
1919
};
2020
use sea_orm_migration::MigratorTrait;
2121
use std::fmt::Write as FmtWrites;
@@ -86,8 +86,8 @@ impl MultiDb {
8686
/// This function will return an error if IO fails
8787
#[allow(clippy::match_wildcard_for_single_variants)]
8888
pub async fn verify_access(db: &DatabaseConnection) -> AppResult<()> {
89-
match db {
90-
DatabaseConnection::SqlxPostgresPoolConnection(_) => {
89+
match db.inner {
90+
DatabaseConnectionType::SqlxPostgresPoolConnection(_) => {
9191
let res = db
9292
.query_all_raw(Statement::from_string(
9393
DatabaseBackend::Postgres,
@@ -100,7 +100,7 @@ pub async fn verify_access(db: &DatabaseConnection) -> AppResult<()> {
100100
));
101101
}
102102
}
103-
DatabaseConnection::Disconnected => {
103+
DatabaseConnectionType::Disconnected => {
104104
return Err(Error::string("connection to database has been closed"));
105105
}
106106
_ => {}

0 commit comments

Comments
 (0)