From 87c8e64698cb046df0cee7f75567a5afb50d98af Mon Sep 17 00:00:00 2001 From: tycrek Date: Wed, 7 Dec 2022 14:40:18 -0700 Subject: [PATCH] fix: remove this method for duplicating the list (ironically correctly) --- src/auth.ts | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/auth.ts b/src/auth.ts index 85b310f..0afac37 100644 --- a/src/auth.ts +++ b/src/auth.ts @@ -195,9 +195,9 @@ export const verifyValidToken = (req: Request) => { return req.headers.authorization && findFromToken(req.headers.authorization); }; -// todo: This is definitely broken +// todo: move inside of onStart (currently broken) // Monitor auth.json for changes (triggered by running 'npm run new-token') -fs.watch(path('auth.json'), { persistent: false }, +/* fs.watch(path('auth.json'), { persistent: false }, (eventType: String) => eventType === 'change' && fs.readJson(path('auth.json')) .then((json: { users: JSON[] }) => { if (!(arrayEquals(Object.keys(users), Object.keys(json.users)))) { @@ -207,3 +207,4 @@ fs.watch(path('auth.json'), { persistent: false }, } }) .catch(console.error)); + */ \ No newline at end of file