Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions src/json.ts
Original file line number Diff line number Diff line change
Expand Up @@ -29,14 +29,14 @@ export class JsonFeed extends BaseFeed<JsonItem> {
home_page_url: this.options.link,
feed_url: this.options.feed,
icon: this.options.icon,
updated: this.options.updated?.toISOString(),
items: this.items.map((
{ id, title, url, date_published, content_html },
) => ({
id,
title,
url,
date_published: date_published?.toISOString() || new Date().toUTCString,
date_published: date_published?.toISOString() ||
new Date().toUTCString(),
...(content_html && { content_html }),
})),
};
Expand Down
1 change: 0 additions & 1 deletion src/rss.ts
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,6 @@ export class RssFeed extends BaseFeed<RssItem> {
const emailPart = escapedEmail ? `${escapedEmail} ` : "";
return (
` <webMaster>${emailPart}(${escapedName})</webMaster>\n` +
` <author>${emailPart}(${escapedName})</author>\n` +
` <managingEditor>${emailPart}(${escapedName})</managingEditor>\n`
);
}).join("");
Expand Down
2 changes: 0 additions & 2 deletions test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,6 @@ Deno.test("RSS Feed Generation", () => {
<language>en-US</language>
<generator>@feed/feed on JSR.io</generator>
<webMaster>[email protected] (John Doe)</webMaster>
<author>[email protected] (John Doe)</author>
<managingEditor>[email protected] (John Doe)</managingEditor>
<item>
<title>First RSS Item</title>
Expand Down Expand Up @@ -157,7 +156,6 @@ Deno.test("JSON Feed Generation", () => {
"title": "JSON Feed Example",
"home_page_url": "http://example.com/json-feed",
"feed_url": "http://example.com/json-feed/feed.json",
"updated": "2024-10-19T15:12:56.000Z",
"items": [
{
"id": "1",
Expand Down