From 361a281fa09ba06d00f633994c2c1a16a663c218 Mon Sep 17 00:00:00 2001 From: Ryan Hirsch Date: Mon, 2 Sep 2024 15:30:00 -0500 Subject: [PATCH] support title for remote item --- src/parser/phase/__test__/phase-6.test.ts | 3 ++- src/parser/phase/phase-6.ts | 2 ++ 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/src/parser/phase/__test__/phase-6.test.ts b/src/parser/phase/__test__/phase-6.test.ts index 216fa30..dcab72e 100644 --- a/src/parser/phase/__test__/phase-6.test.ts +++ b/src/parser/phase/__test__/phase-6.test.ts @@ -340,7 +340,7 @@ describe("phase 6", () => { - + `); @@ -358,6 +358,7 @@ describe("phase 6", () => { expect(third).toHaveProperty("feedGuid", "a5ad6f3f-a279-504c-bc6a-30054e6b50e1"); expect(fourth).toHaveProperty("itemGuid", "tag:soundcloud,2010:tracks/319789777"); expect(fourth).toHaveProperty("feedGuid", "a5ad6f3f-a279-504c-bc6a-30054e6b50e1"); + expect(fourth).toHaveProperty("title", "some title"); expect(helpers.getPhaseSupport(result, phase)).toContain(supportedName); }); }); diff --git a/src/parser/phase/phase-6.ts b/src/parser/phase/phase-6.ts index 6eaefe9..7401ff0 100644 --- a/src/parser/phase/phase-6.ts +++ b/src/parser/phase/phase-6.ts @@ -39,6 +39,7 @@ export type Phase6RemoteItem = { itemGuid?: string; feedUrl?: string; medium?: Phase4Medium; + title?: string; }; export const remoteItem = { @@ -56,6 +57,7 @@ export const remoteItem = { feedGuid: getKnownAttribute(n, "feedGuid"), ...extractOptionalStringAttribute(n, "itemGuid"), ...extractOptionalStringAttribute(n, "feedUrl"), + ...extractOptionalStringAttribute(n, "title"), ...(getAttribute(n, "medium") ? { medium: lookup(Phase4Medium, getKnownAttribute(n, "medium")) } : undefined),