diff --git a/src/main/events/profile/get-user-profile.ts b/src/main/events/profile/get-user-profile.ts index 536b1ce5..6f2179ef 100644 --- a/src/main/events/profile/get-user-profile.ts +++ b/src/main/events/profile/get-user-profile.ts @@ -4,6 +4,7 @@ import { logger } from "@main/services"; import { HydraApi } from "@main/services/hydra-api"; import { steamGamesWorker } from "@main/workers"; import { UserProfile } from "@types"; +import { convertSteamGameToCatalogueEntry } from "../helpers/search-games"; const getUserProfile = async ( _event: Electron.IpcMainInvokeEvent, @@ -19,7 +20,7 @@ const getUserProfile = async ( name: "getById", }); - return { ...game, title: steamGame.name, objectId: game.objectId }; + return convertSteamGameToCatalogueEntry(steamGame); }) ); @@ -28,7 +29,7 @@ const getUserProfile = async ( const steamGame = await steamGamesWorker.run(Number(game.objectId), { name: "getById", }); - return { ...game, title: steamGame.name, objectID: game.objectId }; + return convertSteamGameToCatalogueEntry(steamGame); }) ); diff --git a/src/renderer/src/pages/profile/profile-content.tsx b/src/renderer/src/pages/profile/profile-content.tsx index 9fa8b1a9..e5bed56c 100644 --- a/src/renderer/src/pages/profile/profile-content.tsx +++ b/src/renderer/src/pages/profile/profile-content.tsx @@ -16,7 +16,7 @@ export const ProfileContent = ({ userProfile }: ProfileContentProps) => {
@@ -53,7 +53,12 @@ export const ProfileContent = ({ userProfile }: ProfileContentProps) => { style={{ flexDirection: "column" }} > {userProfile.recentGames.map((game) => { - return

{game.title}

; + return ( + <> + +

{game.title}

+ + ); })}
@@ -84,7 +89,12 @@ export const ProfileContent = ({ userProfile }: ProfileContentProps) => { style={{ flexDirection: "column" }} > {userProfile.libraryGames.map((game) => { - return

{game.title}

; + return ( + <> + {" "} +

{game.title}

+ + ); })}