Skip to content

Commit 1a437bb

Browse files
authored
Update account.html
1 parent 0851294 commit 1a437bb

File tree

1 file changed

+1
-6
lines changed

1 file changed

+1
-6
lines changed

src/account.html

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -124,7 +124,7 @@
124124

125125
function checkAuth() {
126126
const authSuccess = new URLSearchParams(window.location.search).get('success');
127-
const username = new URLSearchParams(window.location.search).get('username');
127+
const username = new URLSearchParams(window.location.search).get('username')?.trim().toLowerCase();
128128

129129
if (username) {
130130
const decodedUsername = decodeUsername(username); // Decode the username using atob
@@ -170,11 +170,6 @@
170170
}
171171

172172
async function strikeinfo() {
173-
// Retrieve the 'username' parameter from the URL
174-
const urlParams = new URLSearchParams(window.location.search);
175-
const encodedUsername = urlParams.get('username');
176-
const username = decodeUsername(encodedUsername); // Decode the username using atob
177-
178173
window.location.href = `https://scratch-coding-hut.netlify.app/Strikes/my-strikes?username=${username}`;
179174
}
180175
</script>

0 commit comments

Comments
 (0)