Fixed wrong count

This commit is contained in:
Joao Ramos
2024-07-13 17:25:10 +01:00
parent 8d39a20267
commit 60d436b5b9

View File

@@ -168,9 +168,6 @@ export default function MasterCorporateDashboard({ user }: Props) {
}; };
const GroupsList = () => { const GroupsList = () => {
const filter = (x: Group) =>
x.admin === user.id || x.participants.includes(user.id);
return ( return (
<> <>
<div className="flex flex-col gap-4"> <div className="flex flex-col gap-4">
@@ -182,7 +179,7 @@ export default function MasterCorporateDashboard({ user }: Props) {
<span>Back</span> <span>Back</span>
</div> </div>
<h2 className="text-2xl font-semibold"> <h2 className="text-2xl font-semibold">
Groups ({groups.filter(filter).length}) Groups ({groups.length})
</h2> </h2>
</div> </div>