Skip to content

Commit 685bbcb

Browse files
committed
Increase timeout
1 parent 7d93010 commit 685bbcb

File tree

1 file changed

+2
-4
lines changed

1 file changed

+2
-4
lines changed

pages/pass.tsx

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,6 @@ function Pass(): JSX.Element {
1313

1414
const [fragment, setFragment] = useState<string>(undefined);
1515
const [view, setView] = useState<boolean>(true);
16-
const [resized, setResized] = useState<boolean>(false);
1716

1817
useEffect(() => {
1918
const rawFragment = window.location.hash.substring(1);
@@ -23,13 +22,12 @@ function Pass(): JSX.Element {
2322
}
2423

2524
const resizeTimeout = window.setTimeout(() => {
26-
if (!resized && rawFragment) {
25+
if (rawFragment) {
2726
window.location.replace('/pass/note');
2827
}
29-
}, 100);
28+
}, 200);
3029

3130
window.addEventListener('resize', () => {
32-
setResized(true);
3331
clearTimeout(resizeTimeout);
3432
const decodedFragment = Buffer.from(rawFragment, 'base64').toString();
3533
setFragment(decodedFragment);

0 commit comments

Comments
 (0)