Skip to content

Commit

Permalink
Encode username component in login_as link
Browse files Browse the repository at this point in the history
Resolves #299
  • Loading branch information
jvendetti committed Mar 9, 2024
1 parent 1d54018 commit 364a484
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion app/assets/javascripts/bp_admin.js
Original file line number Diff line number Diff line change
Expand Up @@ -892,7 +892,7 @@ function populateUserRows(data) {
let actions = [
'<a href="/accounts/'+ user['username'] +'" class="mx-1">Detail</a>' ,
'<a href="javascript:;" class="delete-user mx-1" data-account-name="' + username + '">Delete</a>',
'<a href="/login_as/'+ username +'" class="mx-1">Login as</a>',
'<a href="/login_as/'+ encodeURIComponent(username) +'" class="mx-1">Login as</a>',

]
let row = [firstname, lastname, username, email , roles , id , created , actions.join('|')];
Expand Down

0 comments on commit 364a484

Please sign in to comment.