mirror of
https://github.com/bitsocialnet/5chan.git
synced 2026-08-03 07:41:04 +02:00
fix(board buttons): guard against undefined address
This commit is contained in:
@@ -45,7 +45,7 @@ const CatalogButton = ({ address, isInAllView, isInSubscriptionsView, isInModVie
|
|||||||
if (params?.timeFilterName) return `/mod/catalog/${params.timeFilterName}`;
|
if (params?.timeFilterName) return `/mod/catalog/${params.timeFilterName}`;
|
||||||
return `/mod/catalog`;
|
return `/mod/catalog`;
|
||||||
}
|
}
|
||||||
const boardPath = address ? getBoardPath(address, defaultSubplebbits) : address;
|
const boardPath = address ? getBoardPath(address, defaultSubplebbits) : defaultSubplebbits || '';
|
||||||
return `/${boardPath}/catalog`;
|
return `/${boardPath}/catalog`;
|
||||||
};
|
};
|
||||||
|
|
||||||
@@ -83,7 +83,7 @@ const ReturnButton = ({ address, isInAllView, isInSubscriptionsView, isInModView
|
|||||||
if (params?.timeFilterName) return `/mod/${params.timeFilterName}`;
|
if (params?.timeFilterName) return `/mod/${params.timeFilterName}`;
|
||||||
return `/mod`;
|
return `/mod`;
|
||||||
}
|
}
|
||||||
const boardPath = address ? getBoardPath(address, defaultSubplebbits) : address;
|
const boardPath = address ? getBoardPath(address, defaultSubplebbits) : defaultSubplebbits || '';
|
||||||
return `/${boardPath}`;
|
return `/${boardPath}`;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user