mirror of
https://github.com/Radiquum/AniX.git
synced 2025-04-05 07:44:38 +00:00
fix: Error on release and collection page if user isn't authorized
This commit is contained in:
parent
ea44bbf0e1
commit
5b68da425b
3 changed files with 3 additions and 3 deletions
|
@ -27,7 +27,7 @@ export const ReleaseInfoUserList = (props: {
|
|||
setUserList: any;
|
||||
setIsFavorite: any;
|
||||
collection_count: number;
|
||||
profile_id: number;
|
||||
profile_id: number | null;
|
||||
}) => {
|
||||
const [AddReleaseToCollectionModalOpen, setAddReleaseToCollectionModalOpen] =
|
||||
useState(false);
|
||||
|
|
|
@ -97,7 +97,7 @@ export function CollectionsFullPage(props: {
|
|||
sectionTitle={props.title}
|
||||
content={content}
|
||||
isMyCollections={
|
||||
props.type == "profile" && props.profile_id == userStore.user.id
|
||||
props.type == "profile" && userStore.user && props.profile_id == userStore.user.id
|
||||
}
|
||||
/>
|
||||
) : !isLoadingEnd || isLoading ? (
|
||||
|
|
|
@ -86,7 +86,7 @@ export const ReleasePage = (props: any) => {
|
|||
isFavorite={userFavorite}
|
||||
release_id={data.release.id}
|
||||
token={userStore.token}
|
||||
profile_id={userStore.user.id}
|
||||
profile_id={userStore.user ? userStore.user.id : null}
|
||||
setUserList={setUserList}
|
||||
setIsFavorite={setUserFavorite}
|
||||
collection_count={data.release.collection_count}
|
||||
|
|
Loading…
Add table
Reference in a new issue