Skip to content

Commit

Permalink
fix: perk articles
Browse files Browse the repository at this point in the history
  • Loading branch information
hsanger committed Nov 4, 2024
1 parent d0a6cc0 commit c0ea400
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions app/(wiki)/perks/page.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@ import GenericListingPageFactory from "@/components/layouts/GenericListingPageFa
import { PerkCategories, PerkQualities, Perks } from "@/vendor/suroi/common/src/definitions/perks";

const perkDefs = Perks.definitions;
const normalPerks = perkDefs.filter(perk => perk.categories[0] === PerkCategories.Normal);
const halloweenPerks = perkDefs.filter(perk => perk.categories[0] === PerkCategories.Halloween);
const normalPerks = perkDefs.filter(perk => perk.category === PerkCategories.Normal);
const halloweenPerks = perkDefs.filter(perk => perk.category === PerkCategories.Halloween);
const halloweenPerkCountOfType = (type: PerkQualities): number => halloweenPerks.filter(perk => perk.type === type).length;

export default GenericListingPageFactory(
Expand Down
2 changes: 1 addition & 1 deletion components/sidebars/PerkSidebar.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ export default function PerkSidebar({
item: PerkDefinition
}) {
let category;
switch (item.categories[0]) {
switch (item.category) {
case PerkCategories.Normal:
category = "Normal";
break;
Expand Down

0 comments on commit c0ea400

Please sign in to comment.