mirror of
https://github.com/BookStackApp/BookStack.git
synced 2025-06-04 17:04:32 +08:00
Performed review of "public intended" functionality provided in #1817
- Updated logic to take url from referrer rather than pass as a query parameter. - Added tests to cover functionality. - Updated 404 page with login action button if not signed in. - Updated 404 page with text to indicate permissions may be affecting visibility. Related to #1817 and #1706
This commit is contained in:
@ -76,8 +76,9 @@ class LoginController extends Controller
|
||||
]);
|
||||
}
|
||||
|
||||
if ($request->has('intended')) {
|
||||
redirect()->setIntendedUrl($request->get('intended'));
|
||||
$previous = url()->previous('');
|
||||
if (setting('app-public') && $previous && $previous !== url('/login')) {
|
||||
redirect()->setIntendedUrl($previous);
|
||||
}
|
||||
|
||||
return view('auth.login', [
|
||||
|
Reference in New Issue
Block a user