From 7a3c835de44123eb6b617fdf7b87b83af10eff39 Mon Sep 17 00:00:00 2001 From: Charlie Owen Date: Wed, 7 Aug 2019 15:02:41 +0200 Subject: [PATCH] Add ability to override docs option --- src/rss2.ts | 2 +- src/typings/index.ts | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/src/rss2.ts b/src/rss2.ts index ecbc7fb..c430efb 100644 --- a/src/rss2.ts +++ b/src/rss2.ts @@ -17,7 +17,7 @@ export default (ins: Feed) => { link: { _text: options.link }, description: { _text: options.description }, lastBuildDate: { _text: options.updated ? options.updated.toUTCString() : new Date().toUTCString() }, - docs: { _text: "https://validator.w3.org/feed/docs/rss2.html" }, + docs: { _text: options.docs ? options.docs : "https://validator.w3.org/feed/docs/rss2.html" }, generator: { _text: options.generator || generator } } } diff --git a/src/typings/index.ts b/src/typings/index.ts index 6e6ea2b..8155d4b 100644 --- a/src/typings/index.ts +++ b/src/typings/index.ts @@ -36,6 +36,7 @@ export interface FeedOptions { feed?: string; feedLinks?: any; hub?: string; + docs?: string; author?: Author; link?: string;