Make tests pass running with postgres

This commit is contained in:
Ajay Ramachandran
2021-03-07 00:21:56 -05:00
parent 3fe7501802
commit 8729796e87
22 changed files with 208 additions and 173 deletions

View File

@@ -52,7 +52,7 @@ export async function shadowBanUser(req: Request, res: Response) {
//find all previous submissions and unhide them
if (unHideOldSubmissions) {
let segmentsToIgnore = (await db.prepare('all', `SELECT UUID FROM "sponsorTimes" st
let segmentsToIgnore = (await db.prepare('all', `SELECT "UUID" FROM "sponsorTimes" st
JOIN "noSegments" ns on "st"."videoID" = "ns"."videoID" AND st.category = ns.category WHERE "st"."userID" = ?`
, [userID])).map((item: {UUID: string}) => item.UUID);
let allSegments = (await db.prepare('all', `SELECT "UUID" FROM "sponsorTimes" st WHERE "st"."userID" = ?`, [userID]))