web: pass 2 migration

Signed-off-by: Jens Langhammer <jens.langhammer@beryju.org>
This commit is contained in:
Jens Langhammer
2021-05-16 17:53:59 +02:00
parent 1f05484e3c
commit dde1dabf97
29 changed files with 32 additions and 32 deletions

View File

@ -31,7 +31,7 @@ export class SourceSettingsOAuth extends BaseUserSettings {
return html`<p>${t`Connected.`}</p>
<button class="pf-c-button pf-m-danger"
@click=${() => {
return new SourcesApi(DEFAULT_CONFIG).sourcesOauthUserConnectionsDelete({
return new SourcesApi(DEFAULT_CONFIG).sourcesOauthUserConnectionsDestroy({
id: connection.results[0].pk || 0
});
}}>

View File

@ -28,7 +28,7 @@ export class UserSettingsAuthenticatorStatic extends BaseUserSettings {
return;
}
// TODO: Handle multiple devices, currently we assume only one TOTP Device
return new AuthenticatorsApi(DEFAULT_CONFIG).authenticatorsTotpDelete({
return new AuthenticatorsApi(DEFAULT_CONFIG).authenticatorsTotpDestroy({
id: devices.results[0].pk || 0
});
});

View File

@ -43,7 +43,7 @@ export class UserSettingsAuthenticatorTOTP extends BaseUserSettings {
return;
}
// TODO: Handle multiple devices, currently we assume only one TOTP Device
return new AuthenticatorsApi(DEFAULT_CONFIG).authenticatorsStaticDelete({
return new AuthenticatorsApi(DEFAULT_CONFIG).authenticatorsStaticDestroy({
id: devices.results[0].pk || 0
});
});

View File

@ -29,7 +29,7 @@ export class UserSettingsAuthenticatorWebAuthn extends BaseUserSettings {
.obj=${device}
objectLabel=${t`Authenticator`}
.delete=${() => {
return new AuthenticatorsApi(DEFAULT_CONFIG).authenticatorsWebauthnDelete({
return new AuthenticatorsApi(DEFAULT_CONFIG).authenticatorsWebauthnDestroy({
id: device.pk || 0
});
}}>

View File

@ -120,7 +120,7 @@ export class UserTokenList extends Table<Token> {
.obj=${item}
objectLabel=${t`Token`}
.delete=${() => {
return new CoreApi(DEFAULT_CONFIG).coreTokensDelete({
return new CoreApi(DEFAULT_CONFIG).coreTokensDestroy({
identifier: item.identifier
});
}}>