mirror of
https://github.com/cryptpad/cryptpad.git
synced 2026-09-12 19:49:59 +05:00
Fix report with 2FA
This commit is contained in:
parent
5a9fd35d34
commit
6df54a1205
@ -104,11 +104,12 @@ define([
|
||||
var hash;
|
||||
|
||||
nThen(function (waitFor) {
|
||||
// If this instance is configured to enforce MFA for all registered users,
|
||||
// request the login block with no credential to check if it is protected.
|
||||
let done = waitFor();
|
||||
var parsed = Block.parseBlockHash(blockHash);
|
||||
Util.getBlock(parsed.href, { }, waitFor((err, response) => {
|
||||
var sessionToken = LocalStore.getSessionToken() || undefined;
|
||||
Util.getBlock(parsed.href, {
|
||||
bearer: sessionToken
|
||||
}, waitFor((err, response) => {
|
||||
if (err) {
|
||||
waitFor.abort();
|
||||
return void UI.alert('Invalid user');
|
||||
|
||||
Loading…
Reference in New Issue
Block a user