From 9efa91563b425ee200d291cad844091da9b74470 Mon Sep 17 00:00:00 2001 From: Ryan Cohen Date: Thu, 18 Aug 2022 10:23:57 +0900 Subject: [PATCH] fix: update for new typeorm import/selects --- server/lib/watchlistsync.ts | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/server/lib/watchlistsync.ts b/server/lib/watchlistsync.ts index 40eddf55c..2a4d611dd 100644 --- a/server/lib/watchlistsync.ts +++ b/server/lib/watchlistsync.ts @@ -1,4 +1,4 @@ -import { getRepository, Not } from 'typeorm'; +import { Not } from 'typeorm'; import PlexTvAPI from '../api/plextv'; import { User } from '../entity/User'; import Media from '../entity/Media'; @@ -13,6 +13,7 @@ import { RequestPermissionError, } from '../entity/MediaRequest'; import { Permission } from './permissions'; +import { getRepository } from '../datasource'; class WatchlistSync { public async syncWatchlist() { @@ -20,7 +21,7 @@ class WatchlistSync { // Get users who actually have plex tokens const users = await userRepository.find({ - select: ['id', 'plexToken', 'permissions'], + select: { id: true, plexToken: true, permissions: true }, where: { plexToken: Not(''), },