p.id === id);
- navigate(
- post ? `/category/${post.categorySlug}#post-${post.id}` : "/browse",
- { replace: true },
- );
+ navigate(post ? `/browse#post-${post.id}` : "/browse", {
+ replace: true,
+ });
return;
}
@@ -30,7 +29,7 @@ export function PostRedirect() {
`/api/posts/${id}?lang=${encodeURIComponent(langQuery(lang))}`,
)
.then((post) => {
- navigate(`/category/${post.categorySlug}#post-${post.id}`, {
+ navigate(`/browse#post-${post.id}`, {
replace: true,
});
})