Merge branch 'feature/public-login-redirect' of git://github.com/Xiphoseer/BookStack into Xiphoseer-feature/public-login-redirect

This commit is contained in:
Dan Brown 2020-03-14 17:46:30 +00:00
commit a95588dc2e
No known key found for this signature in database
GPG Key ID: 46D9F943C24A2EF9
2 changed files with 5 additions and 1 deletions

View File

@ -76,6 +76,10 @@ class LoginController extends Controller
]);
}
if ($request->has('intended')) {
redirect()->setIntendedUrl($request->get('intended'));
}
return view('auth.login', [
'socialDrivers' => $socialDrivers,
'authMethod' => $authMethod,

View File

@ -45,7 +45,7 @@
@if(setting('registration-enabled') && config('auth.method') === 'standard')
<a href="{{ url('/register') }}">@icon('new-user'){{ trans('auth.sign_up') }}</a>
@endif
<a href="{{ url('/login') }}">@icon('login'){{ trans('auth.log_in') }}</a>
<a href="{{ action('Auth\LoginController@getLogin', ['intended' => url()->current()]) }}">@icon('login'){{ trans('auth.log_in') }}</a>
@endif
</div>
@if(signedInUser())