fix variable name

This commit is contained in:
Abhinav 2022-02-03 13:35:06 +05:30
parent e71fb680ef
commit 496c402177

View file

@ -117,10 +117,10 @@ const PhotoFrame = ({
router.events.on('hashChangeComplete', (url: string) => { router.events.on('hashChangeComplete', (url: string) => {
const start = url.indexOf('#'); const start = url.indexOf('#');
const hash = url.slice(start !== -1 ? start : url.length); const hash = url.slice(start !== -1 ? start : url.length);
const photoSwipeShouldBeOpened = hash.endsWith( const shouldPhotoSwipeBeOpened = hash.endsWith(
PHOTOSWIPE_HASH_SUFFIX PHOTOSWIPE_HASH_SUFFIX
); );
if (photoSwipeShouldBeOpened) { if (shouldPhotoSwipeBeOpened) {
setOpen(true); setOpen(true);
} else { } else {
setOpen(false); setOpen(false);