/* Warnings: - You are about to drop the column `reportedId` on the `Report` table. All the data in the column will be lost. - You are about to drop the column `senderId` on the `Report` table. All the data in the column will be lost. - Added the required column `reportedUserId` to the `Report` table without a default value. This is not possible if the table is not empty. - Added the required column `senderUserId` to the `Report` table without a default value. This is not possible if the table is not empty. */ -- DropForeignKey ALTER TABLE "Report" DROP CONSTRAINT "Report_reportedId_fkey"; -- DropForeignKey ALTER TABLE "Report" DROP CONSTRAINT "Report_senderId_fkey"; -- AlterTable ALTER TABLE "Report" DROP COLUMN "reportedId", DROP COLUMN "senderId", ADD COLUMN "reportedUserId" TEXT NOT NULL, ADD COLUMN "reviewerUserId" TEXT, ADD COLUMN "senderUserId" TEXT NOT NULL; -- AddForeignKey ALTER TABLE "Report" ADD CONSTRAINT "Report_senderUserId_fkey" FOREIGN KEY ("senderUserId") REFERENCES "users"("id") ON DELETE RESTRICT ON UPDATE CASCADE; -- AddForeignKey ALTER TABLE "Report" ADD CONSTRAINT "Report_reportedUserId_fkey" FOREIGN KEY ("reportedUserId") REFERENCES "users"("id") ON DELETE RESTRICT ON UPDATE CASCADE; -- AddForeignKey ALTER TABLE "Report" ADD CONSTRAINT "Report_reviewerUserId_fkey" FOREIGN KEY ("reviewerUserId") REFERENCES "users"("id") ON DELETE SET NULL ON UPDATE CASCADE;