From 678779c2fd63d8eb166b43f535e8635ea3f8c07c Mon Sep 17 00:00:00 2001 From: aecsocket Date: Tue, 10 Feb 2026 12:19:46 +0000 Subject: [PATCH 1/4] wip: fix user delete --- .../labrinth/src/database/models/user_item.rs | 8 +++- apps/labrinth/src/routes/v3/users.rs | 40 +++++++++++-------- 2 files changed, 30 insertions(+), 18 deletions(-) diff --git a/apps/labrinth/src/database/models/user_item.rs b/apps/labrinth/src/database/models/user_item.rs index 4d53b56759..119de1e116 100644 --- a/apps/labrinth/src/database/models/user_item.rs +++ b/apps/labrinth/src/database/models/user_item.rs @@ -7,6 +7,8 @@ use crate::database::redis::RedisPool; use crate::database::{PgTransaction, models}; use crate::models::billing::ChargeStatus; use crate::models::users::Badges; +use crate::routes::ApiError; +use crate::util::error::Context; use ariadne::ids::base62_impl::{parse_base62, to_base62}; use chrono::{DateTime, Utc}; use dashmap::DashMap; @@ -504,8 +506,10 @@ impl DBUser { id: DBUserId, transaction: &mut PgTransaction<'_>, redis: &RedisPool, - ) -> Result, DatabaseError> { - let user = Self::get_id(id, &mut *transaction, redis).await?; + ) -> Result, eyre::Report> { + let user = Self::get_id(id, &mut *transaction, redis) + .await + .wrap_err("failed to get user by ID")?; if let Some(delete_user) = user { DBUser::clear_caches(&[(id, Some(delete_user.username))], redis) diff --git a/apps/labrinth/src/routes/v3/users.rs b/apps/labrinth/src/routes/v3/users.rs index 410e15ed01..5940450b05 100644 --- a/apps/labrinth/src/routes/v3/users.rs +++ b/apps/labrinth/src/routes/v3/users.rs @@ -2,6 +2,7 @@ use std::{collections::HashMap, sync::Arc}; use super::{ApiError, oauth_clients::get_user_clients}; use crate::database::PgPool; +use crate::util::error::Context; use crate::{ auth::{ checks::is_visible_organization, filter_visible_collections, @@ -680,7 +681,7 @@ pub async fn user_delete( pool: web::Data, redis: web::Data, session_queue: web::Data, -) -> Result { +) -> Result<(), ApiError> { let user = get_user_from_headers( &req, &**pool, @@ -690,26 +691,33 @@ pub async fn user_delete( ) .await? .1; - let id_option = DBUser::get(&info.into_inner().0, &**pool, &redis).await?; + let id_option = DBUser::get(&info.into_inner().0, &**pool, &redis) + .await + .wrap_internal_err("failed to get user")?; - if let Some(id) = id_option.map(|x| x.id) { - if !user.role.is_admin() && user.id != id.into() { - return Err(ApiError::CustomAuthentication( - "You do not have permission to delete this user!".to_string(), - )); - } + let id = id_option.map(|x| x.id).ok_or(ApiError::NotFound)?; + if !user.role.is_admin() && user.id != id.into() { + return Err(ApiError::CustomAuthentication( + "You do not have permission to delete this user!".to_string(), + )); + } - let mut transaction = pool.begin().await?; + let mut transaction = pool + .begin() + .await + .wrap_internal_err("failed to begin transaction")?; - let result = DBUser::remove(id, &mut transaction, &redis).await?; + let result = DBUser::remove(id, &mut transaction, &redis) + .await + .wrap_internal_err("failed to remove user")?; - transaction.commit().await?; + transaction + .commit() + .await + .wrap_internal_err("failed to commit transaction")?; - if result.is_some() { - Ok(HttpResponse::NoContent().body("")) - } else { - Err(ApiError::NotFound) - } + if result.is_some() { + Ok(()) } else { Err(ApiError::NotFound) } From a489684126626736853b584d770bdc1b0f1ed792 Mon Sep 17 00:00:00 2001 From: aecsocket Date: Tue, 10 Feb 2026 12:30:37 +0000 Subject: [PATCH 2/4] add wrap_errs --- .../labrinth/src/database/models/user_item.rs | 110 ++++++++++++------ apps/labrinth/src/routes/v2/users.rs | 1 + 2 files changed, 75 insertions(+), 36 deletions(-) diff --git a/apps/labrinth/src/database/models/user_item.rs b/apps/labrinth/src/database/models/user_item.rs index 119de1e116..6199f062a8 100644 --- a/apps/labrinth/src/database/models/user_item.rs +++ b/apps/labrinth/src/database/models/user_item.rs @@ -7,7 +7,6 @@ use crate::database::redis::RedisPool; use crate::database::{PgTransaction, models}; use crate::models::billing::ChargeStatus; use crate::models::users::Badges; -use crate::routes::ApiError; use crate::util::error::Context; use ariadne::ids::base62_impl::{parse_base62, to_base62}; use chrono::{DateTime, Utc}; @@ -513,7 +512,8 @@ impl DBUser { if let Some(delete_user) = user { DBUser::clear_caches(&[(id, Some(delete_user.username))], redis) - .await?; + .await + .wrap_err("failed to clear caches")?; let deleted_user: DBUserId = crate::models::users::DELETED_USER.into(); @@ -528,7 +528,8 @@ impl DBUser { id as DBUserId, ) .execute(&mut *transaction) - .await?; + .await + .wrap_err("failed to update team_members owner")?; sqlx::query!( " @@ -540,7 +541,8 @@ impl DBUser { id as DBUserId, ) .execute(&mut *transaction) - .await?; + .await + .wrap_err("failed to update versions author_id")?; sqlx::query!( " @@ -552,7 +554,8 @@ impl DBUser { id as DBUserId, ) .execute(&mut *transaction) - .await?; + .await + .wrap_err("failed to update shared_instances owner_id")?; use futures::TryStreamExt; let notifications: Vec = sqlx::query!( @@ -565,7 +568,8 @@ impl DBUser { .fetch(&mut *transaction) .map_ok(|m| m.id) .try_collect::>() - .await?; + .await + .wrap_err("failed to fetch notifications")?; sqlx::query!( " @@ -575,7 +579,8 @@ impl DBUser { ¬ifications ) .execute(&mut *transaction) - .await?; + .await + .wrap_err("failed to delete notifications_actions")?; sqlx::query!( " @@ -585,7 +590,8 @@ impl DBUser { id as DBUserId ) .execute(&mut *transaction) - .await?; + .await + .wrap_err("failed to delete notifications_deliveries")?; sqlx::query!( " @@ -595,7 +601,8 @@ impl DBUser { id as DBUserId, ) .execute(&mut *transaction) - .await?; + .await + .wrap_err("failed to delete notifications")?; let user_collections = sqlx::query!( " @@ -608,11 +615,13 @@ impl DBUser { .fetch(&mut *transaction) .map_ok(|x| DBCollectionId(x.id)) .try_collect::>() - .await?; + .await + .wrap_err("failed to fetch user collections")?; for collection_id in user_collections { models::DBCollection::remove(collection_id, transaction, redis) - .await?; + .await + .wrap_err("failed to remove collection")?; } let report_threads = sqlx::query!( @@ -627,10 +636,13 @@ impl DBUser { .fetch(&mut *transaction) .map_ok(|x| DBThreadId(x.id)) .try_collect::>() - .await?; + .await + .wrap_err("failed to fetch report threads")?; for thread_id in report_threads { - models::DBThread::remove_full(thread_id, transaction).await?; + models::DBThread::remove_full(thread_id, transaction) + .await + .wrap_err("failed to remove thread")?; } sqlx::query!( @@ -641,7 +653,8 @@ impl DBUser { id as DBUserId, ) .execute(&mut *transaction) - .await?; + .await + .wrap_err("failed to delete reports")?; sqlx::query!( " @@ -653,7 +666,8 @@ impl DBUser { id as DBUserId, ) .execute(&mut *transaction) - .await?; + .await + .wrap_err("failed to update reports user_id")?; sqlx::query!( " @@ -663,7 +677,8 @@ impl DBUser { id as DBUserId, ) .execute(&mut *transaction) - .await?; + .await + .wrap_err("failed to delete mod_follows")?; sqlx::query!( " @@ -673,7 +688,8 @@ impl DBUser { id as DBUserId, ) .execute(&mut *transaction) - .await?; + .await + .wrap_err("failed to delete team_members")?; sqlx::query!( " @@ -683,7 +699,8 @@ impl DBUser { id as DBUserId, ) .execute(&mut *transaction) - .await?; + .await + .wrap_err("failed to delete payouts_values")?; sqlx::query!( " @@ -695,7 +712,8 @@ impl DBUser { id as DBUserId, ) .execute(&mut *transaction) - .await?; + .await + .wrap_err("failed to update payouts user_id")?; sqlx::query!( r#" @@ -707,7 +725,8 @@ impl DBUser { deleted_user as DBUserId, ) .execute(&mut *transaction) - .await?; + .await + .wrap_err("failed to update threads_messages")?; sqlx::query!( " @@ -717,7 +736,8 @@ impl DBUser { id as DBUserId, ) .execute(&mut *transaction) - .await?; + .await + .wrap_err("failed to delete threads_members")?; sqlx::query!( " @@ -729,7 +749,8 @@ impl DBUser { id as DBUserId, ) .execute(&mut *transaction) - .await?; + .await + .wrap_err("failed to update uploaded_images owner_id")?; sqlx::query!( " @@ -739,7 +760,8 @@ impl DBUser { id as DBUserId, ) .execute(&mut *transaction) - .await?; + .await + .wrap_err("failed to delete sessions")?; sqlx::query!( " @@ -749,7 +771,8 @@ impl DBUser { id as DBUserId, ) .execute(&mut *transaction) - .await?; + .await + .wrap_err("failed to delete pats")?; sqlx::query!( " @@ -759,7 +782,8 @@ impl DBUser { id as DBUserId, ) .execute(&mut *transaction) - .await?; + .await + .wrap_err("failed to delete friends")?; sqlx::query!( " @@ -770,7 +794,8 @@ impl DBUser { id as DBUserId, ) .execute(&mut *transaction) - .await?; + .await + .wrap_err("failed to update affiliate_codes created_by")?; sqlx::query!( " @@ -779,7 +804,8 @@ impl DBUser { id as DBUserId, ) .execute(&mut *transaction) - .await?; + .await + .wrap_err("failed to delete affiliate_codes")?; sqlx::query!( " @@ -790,7 +816,8 @@ impl DBUser { id as DBUserId, ) .execute(&mut *transaction) - .await?; + .await + .wrap_err("failed to update payouts_values user_id")?; sqlx::query!( " @@ -799,7 +826,8 @@ impl DBUser { id as DBUserId, ) .execute(&mut *transaction) - .await?; + .await + .wrap_err("failed to delete payouts_values_notifications")?; sqlx::query!( " @@ -811,21 +839,28 @@ impl DBUser { id as DBUserId, ) .execute(&mut *transaction) - .await?; + .await + .wrap_err("failed to update charges user_id")?; let open_subscriptions = - DBUserSubscription::get_all_user(id, &mut *transaction).await?; + DBUserSubscription::get_all_user(id, &mut *transaction) + .await + .wrap_err("failed to get user subscriptions")?; for x in open_subscriptions { let charge = DBCharge::get_open_subscription(x.id, &mut *transaction) - .await?; + .await + .wrap_err("failed to get open subscription charge")?; if let Some(mut charge) = charge { charge.status = ChargeStatus::Cancelled; charge.due = Utc::now(); charge.user_id = deleted_user; - charge.upsert(transaction).await?; + charge + .upsert(transaction) + .await + .wrap_err("failed to upsert charge")?; } } @@ -839,7 +874,8 @@ impl DBUser { id as DBUserId, ) .execute(&mut *transaction) - .await?; + .await + .wrap_err("failed to update users_subscriptions user_id")?; sqlx::query!( " @@ -849,7 +885,8 @@ impl DBUser { id as DBUserId, ) .execute(&mut *transaction) - .await?; + .await + .wrap_err("failed to delete user_backup_codes")?; sqlx::query!( " @@ -859,7 +896,8 @@ impl DBUser { id as DBUserId, ) .execute(&mut *transaction) - .await?; + .await + .wrap_err("failed to delete user")?; Ok(Some(())) } else { diff --git a/apps/labrinth/src/routes/v2/users.rs b/apps/labrinth/src/routes/v2/users.rs index edf379b33d..ab858b5b9f 100644 --- a/apps/labrinth/src/routes/v2/users.rs +++ b/apps/labrinth/src/routes/v2/users.rs @@ -251,6 +251,7 @@ pub async fn user_delete( // Returns NoContent, so we don't need to convert to V2 v3::users::user_delete(req, info, pool, redis, session_queue) .await + .map(|()| HttpResponse::NoContent().body("")) .or_else(v2_reroute::flatten_404_error) } From e3f13052e9d599ce3187fde7f6e0910ff7aa568e Mon Sep 17 00:00:00 2001 From: aecsocket Date: Tue, 10 Feb 2026 12:38:41 +0000 Subject: [PATCH 3/4] delete more rows in user deletion --- .../labrinth/src/database/models/user_item.rs | 129 ++++++++++++++---- 1 file changed, 105 insertions(+), 24 deletions(-) diff --git a/apps/labrinth/src/database/models/user_item.rs b/apps/labrinth/src/database/models/user_item.rs index 6199f062a8..970056c46e 100644 --- a/apps/labrinth/src/database/models/user_item.rs +++ b/apps/labrinth/src/database/models/user_item.rs @@ -691,30 +691,6 @@ impl DBUser { .await .wrap_err("failed to delete team_members")?; - sqlx::query!( - " - DELETE FROM payouts_values - WHERE user_id = $1 - ", - id as DBUserId, - ) - .execute(&mut *transaction) - .await - .wrap_err("failed to delete payouts_values")?; - - sqlx::query!( - " - UPDATE payouts - SET user_id = $1 - WHERE user_id = $2 - ", - deleted_user as DBUserId, - id as DBUserId, - ) - .execute(&mut *transaction) - .await - .wrap_err("failed to update payouts user_id")?; - sqlx::query!( r#" UPDATE threads_messages @@ -899,6 +875,111 @@ impl DBUser { .await .wrap_err("failed to delete user")?; + sqlx::query!( + " + DELETE FROM oauth_client_authorizations + WHERE user_id = $1 + ", + id as DBUserId, + ) + .execute(&mut *transaction) + .await + .wrap_err("failed to delete oauth_client_authorizations")?; + + sqlx::query!( + " + DELETE FROM shared_instance_users + WHERE user_id = $1 + ", + id as DBUserId, + ) + .execute(&mut *transaction) + .await + .wrap_err("failed to delete shared_instance_users")?; + + sqlx::query!( + " + DELETE FROM shared_instance_invited_users + WHERE invited_user_id = $1 + ", + id as DBUserId, + ) + .execute(&mut *transaction) + .await + .wrap_err("failed to delete shared_instance_invited_users")?; + + sqlx::query!( + " + UPDATE users_redeemals + SET user_id = $1 + WHERE user_id = $2 + ", + deleted_user as DBUserId, + id as DBUserId, + ) + .execute(&mut *transaction) + .await + .wrap_err("failed to delete users_redeemals")?; + + sqlx::query!( + " + UPDATE users_compliance + SET user_id = $1 + WHERE user_id = $2 + ", + deleted_user as DBUserId, + id as DBUserId, + ) + .execute(&mut *transaction) + .await + .wrap_err("failed to delete users_compliance")?; + + sqlx::query!( + " + DELETE FROM user_limits + WHERE user_id = $1 + ", + id as DBUserId, + ) + .execute(&mut *transaction) + .await + .wrap_err("failed to delete user_limits")?; + + sqlx::query!( + " + DELETE FROM users_notifications_preferences + WHERE user_id = $1 + ", + id as DBUserId, + ) + .execute(&mut *transaction) + .await + .wrap_err("failed to delete users_notifications_preferences")?; + + sqlx::query!( + " + DELETE FROM moderation_locks + WHERE moderator_id = $1 + ", + id as DBUserId, + ) + .execute(&mut *transaction) + .await + .wrap_err("failed to delete moderation_locks")?; + + sqlx::query!( + " + UPDATE oauth_clients + SET created_by = $1 + WHERE created_by = $2 + ", + deleted_user as DBUserId, + id as DBUserId, + ) + .execute(&mut *transaction) + .await + .wrap_err("failed to update oauth_clients created_by")?; + Ok(Some(())) } else { Ok(None) From 9b17be323feb04a599e82ec484d41cc9ceca804b Mon Sep 17 00:00:00 2001 From: aecsocket Date: Tue, 10 Feb 2026 12:40:41 +0000 Subject: [PATCH 4/4] sqlx prepare --- ...8f44a13be89f18c2099ccb80c2fa1d394f681cebc.json | 15 +++++++++++++++ ...2fcd68178411e8cfa3f3796d7741637f2c2be4850.json | 14 ++++++++++++++ ...8671c3cec00f07f11f3d7972efd9441b263aa6c76.json | 14 ++++++++++++++ ...9c49ac9cb039d2883ee139b6065fc49abb0c6176e.json | 15 +++++++++++++++ ...ac45ab928d15ebda1cf342eb7d25b7fb9e2cd27ca.json | 15 +++++++++++++++ ...3a453baa08664677da4da57192795a9c1d86a6c88.json | 14 ++++++++++++++ ...e1aafd093dd6023259a1e617eeb2c5491e5e5f704.json | 15 --------------- ...b5a454eee3a284573de7efb48e3982f1fb9f6702d.json | 14 ++++++++++++++ ...48faac417fabdb3cb3edd5ed45720598c7c12c689.json | 14 -------------- ...24a0f360fadc01ee609c3c3a9b85618c64d822e55.json | 14 ++++++++++++++ ...8b8eaa27613524fde10df6ec956f198367707078e.json | 14 ++++++++++++++ 11 files changed, 129 insertions(+), 29 deletions(-) create mode 100644 apps/labrinth/.sqlx/query-015d9b9191d9fd0a4de36ea8f44a13be89f18c2099ccb80c2fa1d394f681cebc.json create mode 100644 apps/labrinth/.sqlx/query-05b65c44a55654af963329d2fcd68178411e8cfa3f3796d7741637f2c2be4850.json create mode 100644 apps/labrinth/.sqlx/query-2829629354f77ea579d11be8671c3cec00f07f11f3d7972efd9441b263aa6c76.json create mode 100644 apps/labrinth/.sqlx/query-32e68c09c9dd29dd9e18e139c49ac9cb039d2883ee139b6065fc49abb0c6176e.json create mode 100644 apps/labrinth/.sqlx/query-4e5ae05e21fa85032304a1cac45ab928d15ebda1cf342eb7d25b7fb9e2cd27ca.json create mode 100644 apps/labrinth/.sqlx/query-530b030fe1248d594718dce3a453baa08664677da4da57192795a9c1d86a6c88.json delete mode 100644 apps/labrinth/.sqlx/query-54bfa46679475b799f85494e1aafd093dd6023259a1e617eeb2c5491e5e5f704.json create mode 100644 apps/labrinth/.sqlx/query-7234964dd4ea30d2ccd9742b5a454eee3a284573de7efb48e3982f1fb9f6702d.json delete mode 100644 apps/labrinth/.sqlx/query-92c00ebff25cfb0464947ea48faac417fabdb3cb3edd5ed45720598c7c12c689.json create mode 100644 apps/labrinth/.sqlx/query-b090fca733f427156d50feb24a0f360fadc01ee609c3c3a9b85618c64d822e55.json create mode 100644 apps/labrinth/.sqlx/query-e565b6a2c5e174c261125258b8eaa27613524fde10df6ec956f198367707078e.json diff --git a/apps/labrinth/.sqlx/query-015d9b9191d9fd0a4de36ea8f44a13be89f18c2099ccb80c2fa1d394f681cebc.json b/apps/labrinth/.sqlx/query-015d9b9191d9fd0a4de36ea8f44a13be89f18c2099ccb80c2fa1d394f681cebc.json new file mode 100644 index 0000000000..9512dbe7cf --- /dev/null +++ b/apps/labrinth/.sqlx/query-015d9b9191d9fd0a4de36ea8f44a13be89f18c2099ccb80c2fa1d394f681cebc.json @@ -0,0 +1,15 @@ +{ + "db_name": "PostgreSQL", + "query": "\n UPDATE oauth_clients\n SET created_by = $1\n WHERE created_by = $2\n ", + "describe": { + "columns": [], + "parameters": { + "Left": [ + "Int8", + "Int8" + ] + }, + "nullable": [] + }, + "hash": "015d9b9191d9fd0a4de36ea8f44a13be89f18c2099ccb80c2fa1d394f681cebc" +} diff --git a/apps/labrinth/.sqlx/query-05b65c44a55654af963329d2fcd68178411e8cfa3f3796d7741637f2c2be4850.json b/apps/labrinth/.sqlx/query-05b65c44a55654af963329d2fcd68178411e8cfa3f3796d7741637f2c2be4850.json new file mode 100644 index 0000000000..72a16dc9a9 --- /dev/null +++ b/apps/labrinth/.sqlx/query-05b65c44a55654af963329d2fcd68178411e8cfa3f3796d7741637f2c2be4850.json @@ -0,0 +1,14 @@ +{ + "db_name": "PostgreSQL", + "query": "\n DELETE FROM users_notifications_preferences\n WHERE user_id = $1\n ", + "describe": { + "columns": [], + "parameters": { + "Left": [ + "Int8" + ] + }, + "nullable": [] + }, + "hash": "05b65c44a55654af963329d2fcd68178411e8cfa3f3796d7741637f2c2be4850" +} diff --git a/apps/labrinth/.sqlx/query-2829629354f77ea579d11be8671c3cec00f07f11f3d7972efd9441b263aa6c76.json b/apps/labrinth/.sqlx/query-2829629354f77ea579d11be8671c3cec00f07f11f3d7972efd9441b263aa6c76.json new file mode 100644 index 0000000000..525b1879d6 --- /dev/null +++ b/apps/labrinth/.sqlx/query-2829629354f77ea579d11be8671c3cec00f07f11f3d7972efd9441b263aa6c76.json @@ -0,0 +1,14 @@ +{ + "db_name": "PostgreSQL", + "query": "\n DELETE FROM moderation_locks\n WHERE moderator_id = $1\n ", + "describe": { + "columns": [], + "parameters": { + "Left": [ + "Int8" + ] + }, + "nullable": [] + }, + "hash": "2829629354f77ea579d11be8671c3cec00f07f11f3d7972efd9441b263aa6c76" +} diff --git a/apps/labrinth/.sqlx/query-32e68c09c9dd29dd9e18e139c49ac9cb039d2883ee139b6065fc49abb0c6176e.json b/apps/labrinth/.sqlx/query-32e68c09c9dd29dd9e18e139c49ac9cb039d2883ee139b6065fc49abb0c6176e.json new file mode 100644 index 0000000000..ca4c5dbe26 --- /dev/null +++ b/apps/labrinth/.sqlx/query-32e68c09c9dd29dd9e18e139c49ac9cb039d2883ee139b6065fc49abb0c6176e.json @@ -0,0 +1,15 @@ +{ + "db_name": "PostgreSQL", + "query": "\n UPDATE users_compliance\n SET user_id = $1\n WHERE user_id = $2\n ", + "describe": { + "columns": [], + "parameters": { + "Left": [ + "Int8", + "Int8" + ] + }, + "nullable": [] + }, + "hash": "32e68c09c9dd29dd9e18e139c49ac9cb039d2883ee139b6065fc49abb0c6176e" +} diff --git a/apps/labrinth/.sqlx/query-4e5ae05e21fa85032304a1cac45ab928d15ebda1cf342eb7d25b7fb9e2cd27ca.json b/apps/labrinth/.sqlx/query-4e5ae05e21fa85032304a1cac45ab928d15ebda1cf342eb7d25b7fb9e2cd27ca.json new file mode 100644 index 0000000000..9c2bc1799f --- /dev/null +++ b/apps/labrinth/.sqlx/query-4e5ae05e21fa85032304a1cac45ab928d15ebda1cf342eb7d25b7fb9e2cd27ca.json @@ -0,0 +1,15 @@ +{ + "db_name": "PostgreSQL", + "query": "\n UPDATE users_redeemals\n SET user_id = $1\n WHERE user_id = $2\n ", + "describe": { + "columns": [], + "parameters": { + "Left": [ + "Int8", + "Int8" + ] + }, + "nullable": [] + }, + "hash": "4e5ae05e21fa85032304a1cac45ab928d15ebda1cf342eb7d25b7fb9e2cd27ca" +} diff --git a/apps/labrinth/.sqlx/query-530b030fe1248d594718dce3a453baa08664677da4da57192795a9c1d86a6c88.json b/apps/labrinth/.sqlx/query-530b030fe1248d594718dce3a453baa08664677da4da57192795a9c1d86a6c88.json new file mode 100644 index 0000000000..822b466633 --- /dev/null +++ b/apps/labrinth/.sqlx/query-530b030fe1248d594718dce3a453baa08664677da4da57192795a9c1d86a6c88.json @@ -0,0 +1,14 @@ +{ + "db_name": "PostgreSQL", + "query": "\n DELETE FROM oauth_client_authorizations\n WHERE user_id = $1\n ", + "describe": { + "columns": [], + "parameters": { + "Left": [ + "Int8" + ] + }, + "nullable": [] + }, + "hash": "530b030fe1248d594718dce3a453baa08664677da4da57192795a9c1d86a6c88" +} diff --git a/apps/labrinth/.sqlx/query-54bfa46679475b799f85494e1aafd093dd6023259a1e617eeb2c5491e5e5f704.json b/apps/labrinth/.sqlx/query-54bfa46679475b799f85494e1aafd093dd6023259a1e617eeb2c5491e5e5f704.json deleted file mode 100644 index dbdd85fcea..0000000000 --- a/apps/labrinth/.sqlx/query-54bfa46679475b799f85494e1aafd093dd6023259a1e617eeb2c5491e5e5f704.json +++ /dev/null @@ -1,15 +0,0 @@ -{ - "db_name": "PostgreSQL", - "query": "\n UPDATE payouts\n SET user_id = $1\n WHERE user_id = $2\n ", - "describe": { - "columns": [], - "parameters": { - "Left": [ - "Int8", - "Int8" - ] - }, - "nullable": [] - }, - "hash": "54bfa46679475b799f85494e1aafd093dd6023259a1e617eeb2c5491e5e5f704" -} diff --git a/apps/labrinth/.sqlx/query-7234964dd4ea30d2ccd9742b5a454eee3a284573de7efb48e3982f1fb9f6702d.json b/apps/labrinth/.sqlx/query-7234964dd4ea30d2ccd9742b5a454eee3a284573de7efb48e3982f1fb9f6702d.json new file mode 100644 index 0000000000..7a3fe5769d --- /dev/null +++ b/apps/labrinth/.sqlx/query-7234964dd4ea30d2ccd9742b5a454eee3a284573de7efb48e3982f1fb9f6702d.json @@ -0,0 +1,14 @@ +{ + "db_name": "PostgreSQL", + "query": "\n DELETE FROM shared_instance_invited_users\n WHERE invited_user_id = $1\n ", + "describe": { + "columns": [], + "parameters": { + "Left": [ + "Int8" + ] + }, + "nullable": [] + }, + "hash": "7234964dd4ea30d2ccd9742b5a454eee3a284573de7efb48e3982f1fb9f6702d" +} diff --git a/apps/labrinth/.sqlx/query-92c00ebff25cfb0464947ea48faac417fabdb3cb3edd5ed45720598c7c12c689.json b/apps/labrinth/.sqlx/query-92c00ebff25cfb0464947ea48faac417fabdb3cb3edd5ed45720598c7c12c689.json deleted file mode 100644 index 133a13f0d8..0000000000 --- a/apps/labrinth/.sqlx/query-92c00ebff25cfb0464947ea48faac417fabdb3cb3edd5ed45720598c7c12c689.json +++ /dev/null @@ -1,14 +0,0 @@ -{ - "db_name": "PostgreSQL", - "query": "\n DELETE FROM payouts_values\n WHERE user_id = $1\n ", - "describe": { - "columns": [], - "parameters": { - "Left": [ - "Int8" - ] - }, - "nullable": [] - }, - "hash": "92c00ebff25cfb0464947ea48faac417fabdb3cb3edd5ed45720598c7c12c689" -} diff --git a/apps/labrinth/.sqlx/query-b090fca733f427156d50feb24a0f360fadc01ee609c3c3a9b85618c64d822e55.json b/apps/labrinth/.sqlx/query-b090fca733f427156d50feb24a0f360fadc01ee609c3c3a9b85618c64d822e55.json new file mode 100644 index 0000000000..cbfc0e0b0e --- /dev/null +++ b/apps/labrinth/.sqlx/query-b090fca733f427156d50feb24a0f360fadc01ee609c3c3a9b85618c64d822e55.json @@ -0,0 +1,14 @@ +{ + "db_name": "PostgreSQL", + "query": "\n DELETE FROM shared_instance_users\n WHERE user_id = $1\n ", + "describe": { + "columns": [], + "parameters": { + "Left": [ + "Int8" + ] + }, + "nullable": [] + }, + "hash": "b090fca733f427156d50feb24a0f360fadc01ee609c3c3a9b85618c64d822e55" +} diff --git a/apps/labrinth/.sqlx/query-e565b6a2c5e174c261125258b8eaa27613524fde10df6ec956f198367707078e.json b/apps/labrinth/.sqlx/query-e565b6a2c5e174c261125258b8eaa27613524fde10df6ec956f198367707078e.json new file mode 100644 index 0000000000..289246d710 --- /dev/null +++ b/apps/labrinth/.sqlx/query-e565b6a2c5e174c261125258b8eaa27613524fde10df6ec956f198367707078e.json @@ -0,0 +1,14 @@ +{ + "db_name": "PostgreSQL", + "query": "\n DELETE FROM user_limits\n WHERE user_id = $1\n ", + "describe": { + "columns": [], + "parameters": { + "Left": [ + "Int8" + ] + }, + "nullable": [] + }, + "hash": "e565b6a2c5e174c261125258b8eaa27613524fde10df6ec956f198367707078e" +}