chore: lowercase all emails

This commit is contained in:
Nicolas Meienberger 2026-01-11 14:06:46 +01:00
parent f0871ece52
commit 52280be3c2
3 changed files with 1362 additions and 1478 deletions

View file

@ -0,0 +1,2 @@
-- Custom SQL migration file, put your code below! --
UPDATE users_table SET email = LOWER(TRIM(email));

View file

@ -1,8 +1,8 @@
{
"id": "ad86ee2a-231e-45d1-9910-e4b7cac6a8af",
"prevId": "ae0e3a39-ef4d-4d39-bb97-d67d49193bc7",
"version": "6",
"dialect": "sqlite",
"id": "2d6b79a4-2d75-4240-8943-1180372847ba",
"prevId": "ae0e3a39-ef4d-4d39-bb97-d67d49193bc7",
"tables": {
"account": {
"name": "account",
@ -104,9 +104,7 @@
"indexes": {
"account_userId_idx": {
"name": "account_userId_idx",
"columns": [
"user_id"
],
"columns": ["user_id"],
"isUnique": false
}
},
@ -114,15 +112,11 @@
"account_user_id_users_table_id_fk": {
"name": "account_user_id_users_table_id_fk",
"tableFrom": "account",
"columnsFrom": ["user_id"],
"tableTo": "users_table",
"columnsFrom": [
"user_id"
],
"columnsTo": [
"id"
],
"onDelete": "cascade",
"onUpdate": "no action"
"columnsTo": ["id"],
"onUpdate": "no action",
"onDelete": "cascade"
}
},
"compositePrimaryKeys": {},
@ -234,10 +228,7 @@
"indexes": {
"backup_schedule_mirrors_table_schedule_id_repository_id_unique": {
"name": "backup_schedule_mirrors_table_schedule_id_repository_id_unique",
"columns": [
"schedule_id",
"repository_id"
],
"columns": ["schedule_id", "repository_id"],
"isUnique": true
}
},
@ -245,28 +236,20 @@
"backup_schedule_mirrors_table_schedule_id_backup_schedules_table_id_fk": {
"name": "backup_schedule_mirrors_table_schedule_id_backup_schedules_table_id_fk",
"tableFrom": "backup_schedule_mirrors_table",
"columnsFrom": ["schedule_id"],
"tableTo": "backup_schedules_table",
"columnsFrom": [
"schedule_id"
],
"columnsTo": [
"id"
],
"onDelete": "cascade",
"onUpdate": "no action"
"columnsTo": ["id"],
"onUpdate": "no action",
"onDelete": "cascade"
},
"backup_schedule_mirrors_table_repository_id_repositories_table_id_fk": {
"name": "backup_schedule_mirrors_table_repository_id_repositories_table_id_fk",
"tableFrom": "backup_schedule_mirrors_table",
"columnsFrom": ["repository_id"],
"tableTo": "repositories_table",
"columnsFrom": [
"repository_id"
],
"columnsTo": [
"id"
],
"onDelete": "cascade",
"onUpdate": "no action"
"columnsTo": ["id"],
"onUpdate": "no action",
"onDelete": "cascade"
}
},
"compositePrimaryKeys": {},
@ -336,36 +319,25 @@
"backup_schedule_notifications_table_schedule_id_backup_schedules_table_id_fk": {
"name": "backup_schedule_notifications_table_schedule_id_backup_schedules_table_id_fk",
"tableFrom": "backup_schedule_notifications_table",
"columnsFrom": ["schedule_id"],
"tableTo": "backup_schedules_table",
"columnsFrom": [
"schedule_id"
],
"columnsTo": [
"id"
],
"onDelete": "cascade",
"onUpdate": "no action"
"columnsTo": ["id"],
"onUpdate": "no action",
"onDelete": "cascade"
},
"backup_schedule_notifications_table_destination_id_notification_destinations_table_id_fk": {
"name": "backup_schedule_notifications_table_destination_id_notification_destinations_table_id_fk",
"tableFrom": "backup_schedule_notifications_table",
"columnsFrom": ["destination_id"],
"tableTo": "notification_destinations_table",
"columnsFrom": [
"destination_id"
],
"columnsTo": [
"id"
],
"onDelete": "cascade",
"onUpdate": "no action"
"columnsTo": ["id"],
"onUpdate": "no action",
"onDelete": "cascade"
}
},
"compositePrimaryKeys": {
"backup_schedule_notifications_table_schedule_id_destination_id_pk": {
"columns": [
"schedule_id",
"destination_id"
],
"columns": ["schedule_id", "destination_id"],
"name": "backup_schedule_notifications_table_schedule_id_destination_id_pk"
}
},
@ -520,16 +492,12 @@
"indexes": {
"backup_schedules_table_short_id_unique": {
"name": "backup_schedules_table_short_id_unique",
"columns": [
"short_id"
],
"columns": ["short_id"],
"isUnique": true
},
"backup_schedules_table_name_unique": {
"name": "backup_schedules_table_name_unique",
"columns": [
"name"
],
"columns": ["name"],
"isUnique": true
}
},
@ -537,28 +505,20 @@
"backup_schedules_table_volume_id_volumes_table_id_fk": {
"name": "backup_schedules_table_volume_id_volumes_table_id_fk",
"tableFrom": "backup_schedules_table",
"columnsFrom": ["volume_id"],
"tableTo": "volumes_table",
"columnsFrom": [
"volume_id"
],
"columnsTo": [
"id"
],
"onDelete": "cascade",
"onUpdate": "no action"
"columnsTo": ["id"],
"onUpdate": "no action",
"onDelete": "cascade"
},
"backup_schedules_table_repository_id_repositories_table_id_fk": {
"name": "backup_schedules_table_repository_id_repositories_table_id_fk",
"tableFrom": "backup_schedules_table",
"columnsFrom": ["repository_id"],
"tableTo": "repositories_table",
"columnsFrom": [
"repository_id"
],
"columnsTo": [
"id"
],
"onDelete": "cascade",
"onUpdate": "no action"
"columnsTo": ["id"],
"onUpdate": "no action",
"onDelete": "cascade"
}
},
"compositePrimaryKeys": {},
@ -624,9 +584,7 @@
"indexes": {
"notification_destinations_table_name_unique": {
"name": "notification_destinations_table_name_unique",
"columns": [
"name"
],
"columns": ["name"],
"isUnique": true
}
},
@ -703,54 +661,6 @@
"notNull": false,
"autoincrement": false
},
"upload_limit_enabled": {
"name": "upload_limit_enabled",
"type": "integer",
"primaryKey": false,
"notNull": true,
"autoincrement": false,
"default": false
},
"upload_limit_value": {
"name": "upload_limit_value",
"type": "integer",
"primaryKey": false,
"notNull": true,
"autoincrement": false,
"default": 0
},
"upload_limit_unit": {
"name": "upload_limit_unit",
"type": "text",
"primaryKey": false,
"notNull": true,
"autoincrement": false,
"default": "'MB/s'"
},
"download_limit_enabled": {
"name": "download_limit_enabled",
"type": "integer",
"primaryKey": false,
"notNull": true,
"autoincrement": false,
"default": false
},
"download_limit_value": {
"name": "download_limit_value",
"type": "integer",
"primaryKey": false,
"notNull": true,
"autoincrement": false,
"default": 0
},
"download_limit_unit": {
"name": "download_limit_unit",
"type": "text",
"primaryKey": false,
"notNull": true,
"autoincrement": false,
"default": "'MB/s'"
},
"created_at": {
"name": "created_at",
"type": "integer",
@ -771,9 +681,7 @@
"indexes": {
"repositories_table_short_id_unique": {
"name": "repositories_table_short_id_unique",
"columns": [
"short_id"
],
"columns": ["short_id"],
"isUnique": true
}
},
@ -847,16 +755,12 @@
"indexes": {
"sessions_table_token_unique": {
"name": "sessions_table_token_unique",
"columns": [
"token"
],
"columns": ["token"],
"isUnique": true
},
"sessionsTable_userId_idx": {
"name": "sessionsTable_userId_idx",
"columns": [
"user_id"
],
"columns": ["user_id"],
"isUnique": false
}
},
@ -864,15 +768,11 @@
"sessions_table_user_id_users_table_id_fk": {
"name": "sessions_table_user_id_users_table_id_fk",
"tableFrom": "sessions_table",
"columnsFrom": ["user_id"],
"tableTo": "users_table",
"columnsFrom": [
"user_id"
],
"columnsTo": [
"id"
],
"onDelete": "cascade",
"onUpdate": "no action"
"columnsTo": ["id"],
"onUpdate": "no action",
"onDelete": "cascade"
}
},
"compositePrimaryKeys": {},
@ -914,16 +814,12 @@
"indexes": {
"twoFactor_secret_idx": {
"name": "twoFactor_secret_idx",
"columns": [
"secret"
],
"columns": ["secret"],
"isUnique": false
},
"twoFactor_userId_idx": {
"name": "twoFactor_userId_idx",
"columns": [
"user_id"
],
"columns": ["user_id"],
"isUnique": false
}
},
@ -931,15 +827,11 @@
"two_factor_user_id_users_table_id_fk": {
"name": "two_factor_user_id_users_table_id_fk",
"tableFrom": "two_factor",
"columnsFrom": ["user_id"],
"tableTo": "users_table",
"columnsFrom": [
"user_id"
],
"columnsTo": [
"id"
],
"onDelete": "cascade",
"onUpdate": "no action"
"columnsTo": ["id"],
"onUpdate": "no action",
"onDelete": "cascade"
}
},
"compositePrimaryKeys": {},
@ -1042,16 +934,12 @@
"indexes": {
"users_table_username_unique": {
"name": "users_table_username_unique",
"columns": [
"username"
],
"columns": ["username"],
"isUnique": true
},
"users_table_email_unique": {
"name": "users_table_email_unique",
"columns": [
"email"
],
"columns": ["email"],
"isUnique": true
}
},
@ -1111,9 +999,7 @@
"indexes": {
"verification_identifier_idx": {
"name": "verification_identifier_idx",
"columns": [
"identifier"
],
"columns": ["identifier"],
"isUnique": false
}
},
@ -1211,16 +1097,12 @@
"indexes": {
"volumes_table_short_id_unique": {
"name": "volumes_table_short_id_unique",
"columns": [
"short_id"
],
"columns": ["short_id"],
"isUnique": true
},
"volumes_table_name_unique": {
"name": "volumes_table_name_unique",
"columns": [
"name"
],
"columns": ["name"],
"isUnique": true
}
},
@ -1233,9 +1115,9 @@
"views": {},
"enums": {},
"_meta": {
"columns": {},
"schemas": {},
"tables": {},
"columns": {}
"tables": {}
},
"internal": {
"indexes": {}

View file

@ -229,8 +229,8 @@
{
"idx": 32,
"version": "6",
"when": 1768040838612,
"tag": "0032_outstanding_ultron",
"when": 1768136755563,
"tag": "0032_lowercase-email",
"breakpoints": true
}
]