зеркало из https://github.com/nextcloud/spreed.git
Show "Wrong password" info when the conversation password was wrong
Signed-off-by: Joas Schilling <coding@schilljs.com>
This commit is contained in:
Родитель
4474986a29
Коммит
8ee67f13c1
|
@ -179,7 +179,9 @@ class PageController extends Controller {
|
|||
$this->talkSession->setPasswordForRoom($token, $token);
|
||||
} else {
|
||||
if ($passwordVerification['url'] === '') {
|
||||
return new TemplateResponse($this->appName, 'authenticate', [], 'guest');
|
||||
return new TemplateResponse($this->appName, 'authenticate', [
|
||||
'wrongpw' => $password !== '',
|
||||
], 'guest');
|
||||
}
|
||||
|
||||
return new RedirectResponse($passwordVerification['url']);
|
||||
|
@ -232,7 +234,9 @@ class PageController extends Controller {
|
|||
$this->talkSession->setPasswordForRoom($token, $token);
|
||||
} else {
|
||||
if ($passwordVerification['url'] === '') {
|
||||
return new TemplateResponse($this->appName, 'authenticate', [], 'guest');
|
||||
return new TemplateResponse($this->appName, 'authenticate', [
|
||||
'wrongpw' => $password !== '',
|
||||
], 'guest');
|
||||
}
|
||||
|
||||
return new RedirectResponse($passwordVerification['url']);
|
||||
|
|
|
@ -6,7 +6,7 @@
|
|||
?>
|
||||
<form method="post">
|
||||
<fieldset class="warning">
|
||||
<?php if (!isset($_['wrongpw'])){ ?>
|
||||
<?php if (!$_['wrongpw']) { ?>
|
||||
<div class="warning-info"><?php p($l->t('This conversation is password-protected')); ?></div>
|
||||
<?php } else { ?>
|
||||
<div class="warning"><?php p($l->t('The password is wrong. Try again.')); ?></div>
|
||||
|
@ -18,7 +18,7 @@
|
|||
placeholder="<?php p($l->t('Password')); ?>" value=""
|
||||
autocomplete="off" autocapitalize="off" autocorrect="off"
|
||||
autofocus />
|
||||
<input type="submit" id="password-submit"
|
||||
<input type="submit" id="password-submit"
|
||||
class="svg icon-confirm input-button-inline" value="" disabled="disabled" />
|
||||
</p>
|
||||
</fieldset>
|
||||
|
|
Загрузка…
Ссылка в новой задаче