mirror of
https://github.com/sct/overseerr.git
synced 2025-09-17 17:24:35 +02:00
feat: user avatars from plex (#53)
This commit is contained in:
@@ -46,6 +46,9 @@ authRoutes.post('/login', async (req, res) => {
|
||||
user.plexToken = body.authToken;
|
||||
await userRepository.save(user);
|
||||
}
|
||||
|
||||
// Update the users avatar with their plex thumbnail (incase it changed)
|
||||
user.avatar = account.thumb;
|
||||
} else {
|
||||
// Here we check if it's the first user. If it is, we create the user with no check
|
||||
// and give them admin permissions
|
||||
@@ -56,6 +59,7 @@ authRoutes.post('/login', async (req, res) => {
|
||||
email: account.email,
|
||||
plexToken: account.authToken,
|
||||
permissions: Permission.ADMIN,
|
||||
avatar: account.thumb,
|
||||
});
|
||||
await userRepository.save(user);
|
||||
}
|
||||
|
Reference in New Issue
Block a user