fix build crash

This commit is contained in:
2022-07-10 17:24:25 -07:00
parent 273f3a1d93
commit c846922baf
2 changed files with 5 additions and 3 deletions

View File

@@ -84,7 +84,7 @@ export const getGalleryPageUrl = (
{ keyword, sortKey },
hash
) => {
const url = new URL(`${window.location.origin}/photogallery/`);
const url = new URL(`${window?.location.origin ?? 'https://chuckdries.com'}/photogallery/`);
if (keyword !== undefined) {
if (keyword === null) {
url.searchParams.delete("filter");