diff --git a/src/views/user-profile/views/groups-container/GroupsContainerView.tsx b/src/views/user-profile/views/groups-container/GroupsContainerView.tsx index a5dcb17f..92fdf691 100644 --- a/src/views/user-profile/views/groups-container/GroupsContainerView.tsx +++ b/src/views/user-profile/views/groups-container/GroupsContainerView.tsx @@ -28,7 +28,7 @@ export const GroupsContainerView: FC = props => useEffect(() => { - if(groups.length > 0 && !selectedGroupId) setSelectedGroupId(groups[0].id); + if(groups.length > 0 && !selectedGroupId) setSelectedGroupId(groups[0].groupId); }, [ groups, selectedGroupId ]); useEffect(() => @@ -49,9 +49,9 @@ export const GroupsContainerView: FC = props =>
{ groups.map((group, index) => { - return
setSelectedGroupId(group.id) } className={ 'profile-groups-item position-relative flex-shrink-0 d-flex align-items-center justify-content-center cursor-pointer' + classNames({ ' active': selectedGroupId === group.id }) }> - { itsMe && favoriteGroup(group.id) } /> } - + return
setSelectedGroupId(group.groupId) } className={ 'profile-groups-item position-relative flex-shrink-0 d-flex align-items-center justify-content-center cursor-pointer' + classNames({ ' active': selectedGroupId === group.groupId }) }> + { itsMe && favoriteGroup(group.groupId) } /> } +
}) }
diff --git a/src/views/user-profile/views/groups-container/GroupsContainerView.types.ts b/src/views/user-profile/views/groups-container/GroupsContainerView.types.ts index 40b273af..0bfdf75e 100644 --- a/src/views/user-profile/views/groups-container/GroupsContainerView.types.ts +++ b/src/views/user-profile/views/groups-container/GroupsContainerView.types.ts @@ -1,8 +1,8 @@ -import { GroupDataParser } from '@nitrots/nitro-renderer'; +import { HabboGroupEntryData } from '@nitrots/nitro-renderer'; export interface GroupsContainerViewProps { itsMe: boolean; - groups: GroupDataParser[]; + groups: HabboGroupEntryData[]; onLeaveGroup: () => void; }