refactor: remove application mfa helper functions (#2852)

This commit is contained in:
Mo
2024-02-19 10:43:05 -06:00
committed by GitHub
parent 74da19add8
commit a455304a7a
5 changed files with 31 additions and 40 deletions

View File

@@ -917,28 +917,6 @@ export class SNApplication implements ApplicationInterface, AppGroupManagedAppli
return service.canAttemptDecryptionOfItem(item)
}
public async isMfaActivated(): Promise<boolean> {
return this.mfa.isMfaActivated()
}
public async generateMfaSecret(): Promise<string> {
return this.mfa.generateMfaSecret()
}
public async getOtpToken(secret: string): Promise<string> {
return this.mfa.getOtpToken(secret)
}
public async enableMfa(secret: string, otpToken: string): Promise<void> {
return this.mfa.enableMfa(secret, otpToken)
}
public async disableMfa(): Promise<void> {
if (await this.protections.authorizeMfaDisable()) {
return this.mfa.disableMfa()
}
}
async isUsingHomeServer(): Promise<boolean> {
const homeServerService = this.dependencies.get<HomeServerServiceInterface>(TYPES.HomeServerService)