mirror of
https://github.com/SrIzan10/echospace.git
synced 2026-06-06 00:56:54 +00:00
feat: github auth
This commit is contained in:
17
prisma/migrations/20241213233617_github_init/migration.sql
Normal file
17
prisma/migrations/20241213233617_github_init/migration.sql
Normal file
@@ -0,0 +1,17 @@
|
||||
/*
|
||||
Warnings:
|
||||
|
||||
- You are about to drop the column `hashed_password` on the `User` table. All the data in the column will be lost.
|
||||
- A unique constraint covering the columns `[githubId]` on the table `User` will be added. If there are existing duplicate values, this will fail.
|
||||
- Added the required column `githubId` to the `User` table without a default value. This is not possible if the table is not empty.
|
||||
|
||||
*/
|
||||
-- DropIndex
|
||||
DROP INDEX "User_username_key";
|
||||
|
||||
-- AlterTable
|
||||
ALTER TABLE "User" DROP COLUMN "hashed_password",
|
||||
ADD COLUMN "githubId" TEXT NOT NULL;
|
||||
|
||||
-- CreateIndex
|
||||
CREATE UNIQUE INDEX "User_githubId_key" ON "User"("githubId");
|
||||
@@ -15,8 +15,8 @@ datasource db {
|
||||
|
||||
model User {
|
||||
id String @id @default(cuid())
|
||||
username String @unique
|
||||
hashed_password String
|
||||
githubId String @unique
|
||||
username String
|
||||
sessions Session[]
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user