mirror of
https://github.com/bitsocialnet/5chan.git
synced 2026-08-03 07:41:04 +02:00
add route validation checks
This commit is contained in:
@@ -2,7 +2,7 @@ import { Post } from '../../views/post';
|
||||
import { useTranslation } from 'react-i18next';
|
||||
import { isAllView } from '../../lib/utils/view-utils';
|
||||
import { useMultisubMetadata } from '../../hooks/use-default-subplebbits';
|
||||
import { useLocation, useParams } from 'react-router-dom';
|
||||
import { useLocation } from 'react-router-dom';
|
||||
|
||||
interface DescriptionPostProps {
|
||||
avatarUrl?: string;
|
||||
@@ -17,7 +17,7 @@ interface DescriptionPostProps {
|
||||
const SubplebbitDescription = ({ avatarUrl, createdAt, description, replyCount, shortAddress, subplebbitAddress, title }: DescriptionPostProps) => {
|
||||
const { t } = useTranslation();
|
||||
const location = useLocation();
|
||||
const isInAllView = isAllView(location.pathname, useParams());
|
||||
const isInAllView = isAllView(location.pathname);
|
||||
const multisubMetadata = useMultisubMetadata();
|
||||
|
||||
const post = {
|
||||
|
||||
Reference in New Issue
Block a user