Don't force full reload to show success screen
This commit is contained in:
parent
e0f2a79d70
commit
dbf64347be
@ -60,11 +60,6 @@ export default function () {
|
||||
};
|
||||
|
||||
useEffect(() => {
|
||||
if (sessionStorage.getItem("REPORT_SUCCESS")) {
|
||||
sessionStorage.removeItem("REPORT_SUCCESS");
|
||||
return setShowSuccess(true);
|
||||
}
|
||||
|
||||
setSupportsRequestStreams(
|
||||
(() => {
|
||||
let duplexAccessed = false;
|
||||
@ -241,6 +236,9 @@ export default function () {
|
||||
method: "POST",
|
||||
});
|
||||
|
||||
// @ts-expect-error
|
||||
turnstile.reset();
|
||||
|
||||
return toast({
|
||||
description: "Failed to upload file",
|
||||
isClosable: true,
|
||||
@ -257,7 +255,7 @@ export default function () {
|
||||
method: "POST",
|
||||
});
|
||||
|
||||
sessionStorage.setItem("REPORT_SUCCESS", "1");
|
||||
setShowSuccess(true);
|
||||
}
|
||||
|
||||
useEffect(() => {
|
||||
|
Loading…
x
Reference in New Issue
Block a user