diff --git a/_cms.ts b/_cms.ts
index 40b2747..d300668 100644
--- a/_cms.ts
+++ b/_cms.ts
@@ -184,14 +184,8 @@ cms.collection(
name: "steam",
type: "object",
label: "Steam",
- description: "",
+ description: "The game, as it is available on Steam.",
fields: [
- {
- name: "platform",
- type: "hidden",
- label: "Platform",
- value: "steam",
- },
{
name: "appid",
type: "text",
diff --git a/_includes/game.tsx b/_includes/game.tsx
index e97e4fa..62edb29 100644
--- a/_includes/game.tsx
+++ b/_includes/game.tsx
@@ -119,7 +119,7 @@ export default function(data: GameData, helpers: Lume.Helpers) {
const milestonesSeparator = ((data.identifiers?.length ?? 0) > 0) ?
: null
const identifiersRows = data.identifiers?.map((identifier: GameIdentifier, index: number) => {
- switch(identifier.platform) {
+ switch(identifier.type) {
case "steam":
return (
i.platform === "steam")
+ const identifiers: GameIdentifier[] = page.data.identifiers.filter((i: GameIdentifier) => i.type === "steam")
let nullify: boolean = false
for(const identifier of identifiers) {
@@ -103,9 +103,9 @@ for(const game of games) {
completed_on: page?.completed_on,
mastered_on: page?.mastered_on,
identifiers: [
- ...(page?.identifiers?.filter(i => i.platform !== "steam") ?? []),
+ ...(page?.identifiers?.filter(i => i.type !== "steam") ?? []),
{
- platform: "steam",
+ type: "steam",
appid: appId,
name: game.name,
synced_on: formatDateIso(new Date())
diff --git a/_utils/game.ts b/_utils/game.ts
index 0453970..59d4ca9 100644
--- a/_utils/game.ts
+++ b/_utils/game.ts
@@ -3,12 +3,12 @@ import {ReviewData} from "./review.ts"
export interface GameBaseIdentifier {
- platform: string,
+ type: string,
synced_on?: string,
}
export interface GameSteamIdentifier extends GameBaseIdentifier {
- platform: "steam",
+ type: "steam",
appid: string,
name?: string,
}