You've already forked authentication-service
mirror of
https://github.com/matrix-org/matrix-authentication-service.git
synced 2025-08-09 04:22:45 +03:00
Upgrade all Rust dependencies
This includes breaking changes of sqlx 0.7.0
This commit is contained in:
@@ -198,7 +198,7 @@ impl Options {
|
||||
|
||||
// TODO: do some pagination here
|
||||
let ids: Vec<Uuid> = sqlx::query_scalar("SELECT user_id FROM users")
|
||||
.fetch_all(&mut conn)
|
||||
.fetch_all(&mut *conn)
|
||||
.await?;
|
||||
drop(conn);
|
||||
|
||||
@@ -235,7 +235,7 @@ impl Options {
|
||||
"#,
|
||||
)
|
||||
.bind(Uuid::from(user.id))
|
||||
.fetch_all(&mut conn)
|
||||
.fetch_all(&mut *conn)
|
||||
.await?;
|
||||
|
||||
for id in compat_sessions_ids {
|
||||
@@ -265,7 +265,7 @@ impl Options {
|
||||
"#,
|
||||
)
|
||||
.bind(Uuid::from(user.id))
|
||||
.fetch_all(&mut conn)
|
||||
.fetch_all(&mut *conn)
|
||||
.await?;
|
||||
|
||||
for id in oauth2_sessions_ids {
|
||||
@@ -300,7 +300,7 @@ impl Options {
|
||||
"#,
|
||||
)
|
||||
.bind(Uuid::from(user.id))
|
||||
.fetch_all(&mut conn)
|
||||
.fetch_all(&mut *conn)
|
||||
.await?;
|
||||
|
||||
for id in user_sessions_ids {
|
||||
|
@@ -121,7 +121,7 @@ pub async fn templates_from_config(
|
||||
|
||||
#[tracing::instrument(name = "db.connect", skip_all, err(Debug))]
|
||||
pub async fn database_from_config(config: &DatabaseConfig) -> Result<PgPool, anyhow::Error> {
|
||||
let mut options = match &config.options {
|
||||
let options = match &config.options {
|
||||
DatabaseConnectConfig::Uri { uri } => uri
|
||||
.parse()
|
||||
.context("could not parse database connection string")?,
|
||||
@@ -164,7 +164,7 @@ pub async fn database_from_config(config: &DatabaseConfig) -> Result<PgPool, any
|
||||
}
|
||||
};
|
||||
|
||||
options
|
||||
let options = options
|
||||
.log_statements(LevelFilter::Debug)
|
||||
.log_slow_statements(LevelFilter::Warn, Duration::from_millis(100));
|
||||
|
||||
|
Reference in New Issue
Block a user