Compare commits
1 Commits
main
...
remove-fir
| Author | SHA1 | Date |
|---|---|---|
|
|
a6a7b169fa |
|
|
@ -47,3 +47,12 @@ Deno.test("generated rss contains promo with link to donations page", () => {
|
|||
"First promotion should come before the second",
|
||||
);
|
||||
});
|
||||
|
||||
Deno.test("first promotion is removed", () => {
|
||||
const series = testUtils.generateSeries();
|
||||
const feed = rss.assembleFeed(series);
|
||||
const indexOfFirstPromotion = feed.indexOf(
|
||||
"NRSS er avhengig av din Vipps-støtte",
|
||||
);
|
||||
assertEquals(indexOfFirstPromotion, -1, "First promotion should be removed");
|
||||
});
|
||||
|
|
|
|||
|
|
@ -53,11 +53,10 @@ function assembleFeed(series: Series): string {
|
|||
}
|
||||
|
||||
function descriptionWithDonationPromotion(description: string): string {
|
||||
const firstPromotion = `⬇️NRSS er avhengig av din Vipps-støtte⬇️`;
|
||||
const secondPromotion =
|
||||
const promotion =
|
||||
`Takk for at du bruker NRSS 🙏🌟 Vurder å støtte utviklingen via Vipps med omtrent det samme som prisen på en kaffekopp. Se mer på https://nrss.deno.dev/`;
|
||||
|
||||
return `${firstPromotion}\n\n${description}\n\n${secondPromotion}`;
|
||||
return `${description}\n\n${promotion}`;
|
||||
}
|
||||
|
||||
function assembleEpisode(episode: Episode, seriesId: Series["id"]): Tag {
|
||||
|
|
|
|||
Loading…
Reference in New Issue