fix: harden cloud storage security
This commit is contained in:
@@ -265,6 +265,11 @@
|
||||
return;
|
||||
}
|
||||
|
||||
const cleanUrl = new URL(window.location.href);
|
||||
cleanUrl.searchParams.delete('verifyToken');
|
||||
cleanUrl.searchParams.delete('token');
|
||||
window.history.replaceState({}, document.title, cleanUrl.pathname + cleanUrl.search + cleanUrl.hash);
|
||||
|
||||
try {
|
||||
const res = await fetch(`/api/verify-email?token=${encodeURIComponent(token)}`);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user