update URL scheme

This commit is contained in:
plebbitor
2023-04-08 22:30:44 +02:00
parent 603c1084a9
commit 60374f5724
7 changed files with 43 additions and 43 deletions
View File
+4 -4
View File
@@ -16,13 +16,13 @@ const useClickForm = () => {
if (location.pathname === "/") {
navigate("/post");
} else if (location.pathname.endsWith("/catalog")) {
navigate(`/${subplebbitAddress}/catalog/post`);
navigate(`/p/${subplebbitAddress}/catalog/post`);
} else if (location.pathname.endsWith("/thread")) {
navigate(`/${subplebbitAddress}/thread/post`);
navigate(`/p/${subplebbitAddress}/c/post`);
} else if (threadCid) {
navigate(`/${subplebbitAddress}/thread/${threadCid}/post`);
navigate(`/p/${subplebbitAddress}/c/${threadCid}/post`);
} else {
navigate(`/${subplebbitAddress}/post`);
navigate(`/p/${subplebbitAddress}/post`);
}
};