fix(backend): use different device ids for jellyfin users

This commit is contained in:
Aiden Vigue
2021-06-17 13:42:08 -04:00
parent dd4d42fd31
commit 5c917f95b4

View File

@@ -189,9 +189,9 @@ authRoutes.post('/jellyfin', async (req, res, next) => {
if (user) { if (user) {
deviceId = user.jellyfinDeviceId ?? ''; deviceId = user.jellyfinDeviceId ?? '';
} else { } else {
deviceId = Buffer.from( deviceId = Buffer.from(`BOT_overseerr_${body.username ?? ''}`).toString(
`Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:85.0) Gecko/20100101 Firefox/85.0` 'base64'
).toString('base64'); );
} }
// First we need to attempt to log the user in to jellyfin // First we need to attempt to log the user in to jellyfin
const jellyfinserver = new JellyfinAPI(hostname ?? '', undefined, deviceId); const jellyfinserver = new JellyfinAPI(hostname ?? '', undefined, deviceId);