Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-ce
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
1
Merge Requests
1
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
gitlab-ce
Commits
614e6d54
Commit
614e6d54
authored
Apr 08, 2022
by
Sheldon Led
Committed by
Miguel Rincon
Apr 08, 2022
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix 404 console error when user is signed out
parent
07d86233
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
4 additions
and
4 deletions
+4
-4
app/views/errors/_footer.html.haml
app/views/errors/_footer.html.haml
+2
-2
app/views/layouts/errors.html.haml
app/views/layouts/errors.html.haml
+2
-2
No files found.
app/views/errors/_footer.html.haml
View file @
614e6d54
...
...
@@ -4,8 +4,8 @@
=
link_to
s_
(
'Nav|Home'
),
root_path
%li
-
if
current_user
=
link_to
s_
(
'Nav|Sign out and sign in with a different account'
),
'#'
,
id:
'sign_out_
link'
%form
{
action:
destroy_user_session_path
,
method: :post
,
id:
'sign_out_form'
}
=
link_to
s_
(
'Nav|Sign out and sign in with a different account'
),
'#'
,
class:
'js-sign-out-
link'
%form
.js-sign-out-form
{
action:
destroy_user_session_path
,
method: :post
}
-
else
=
link_to
s_
(
'Nav|Sign In / Register'
),
new_session_path
(
:user
,
redirect_to_referer:
'yes'
)
%li
...
...
app/views/layouts/errors.html.haml
View file @
614e6d54
...
...
@@ -22,8 +22,8 @@
}
// We do not have rails_ujs here, so we're manually making a link trigger a form submit.
document.
getElementById('sign_out_link').addEventListener('click', function(e)
{
document.
querySelector('.js-sign-out-link')?.addEventListener('click', (e) =>
{
e.preventDefault();
document.
getElementById('sign_out_form')
.submit();
document.
querySelector('.js-sign-out-form')?
.submit();
});
}());
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment