mirror of
https://github.com/Chocobozzz/PeerTube.git
synced 2025-02-25 18:55:32 -06:00
Fix external auth email/password update
Also check if an actor does not already exist when creating the user
This commit is contained in:
@@ -216,7 +216,7 @@ function unblockUser (url: string, userId: number | string, accessToken: string,
|
||||
.expect(expectedStatus)
|
||||
}
|
||||
|
||||
function updateMyUser (options: { url: string, accessToken: string } & UserUpdateMe) {
|
||||
function updateMyUser (options: { url: string, accessToken: string, statusCodeExpected?: number } & UserUpdateMe) {
|
||||
const path = '/api/v1/users/me'
|
||||
|
||||
const toSend: UserUpdateMe = omit(options, 'url', 'accessToken')
|
||||
@@ -226,7 +226,7 @@ function updateMyUser (options: { url: string, accessToken: string } & UserUpdat
|
||||
path,
|
||||
token: options.accessToken,
|
||||
fields: toSend,
|
||||
statusCodeExpected: 204
|
||||
statusCodeExpected: options.statusCodeExpected || 204
|
||||
})
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user