mirror of
https://github.com/BookStackApp/BookStack.git
synced 2025-04-16 01:34:12 +00:00
Users: Hid lanuage preference for guest user
Hiding since it's not really used, and may mislead on how to set default app language (which should be done via env options). Updated test to cover. For #5356
This commit is contained in:
parent
7e1a8e5ec6
commit
a8ef820443
2 changed files with 8 additions and 2 deletions
|
@ -34,7 +34,9 @@
|
|||
</div>
|
||||
</div>
|
||||
|
||||
@include('users.parts.language-option-row', ['value' => old('language') ?? $user->getLocale()->appLocale()])
|
||||
@if(!$user->isGuest())
|
||||
@include('users.parts.language-option-row', ['value' => old('language') ?? $user->getLocale()->appLocale()])
|
||||
@endif
|
||||
</div>
|
||||
|
||||
<div class="text-right">
|
||||
|
|
|
@ -202,9 +202,13 @@ class UserManagementTest extends TestCase
|
|||
public function test_guest_profile_shows_limited_form()
|
||||
{
|
||||
$guest = $this->users->guest();
|
||||
|
||||
$resp = $this->asAdmin()->get('/settings/users/' . $guest->id);
|
||||
$resp->assertSee('Guest');
|
||||
$this->withHtml($resp)->assertElementNotExists('#password');
|
||||
$html = $this->withHtml($resp);
|
||||
|
||||
$html->assertElementNotExists('#password');
|
||||
$html->assertElementNotExists('[name="language"]');
|
||||
}
|
||||
|
||||
public function test_guest_profile_cannot_be_deleted()
|
||||
|
|
Loading…
Add table
Reference in a new issue