fix(core): update

This commit is contained in:
2020-10-28 15:54:39 +00:00
parent 8a78cc6831
commit 3170da0303
2 changed files with 8 additions and 2 deletions

View File

@@ -5,7 +5,13 @@ export class SitemapNews {
constructor(optionsArg: {}) {}
public async readAndAddFromRssFeed(urlArg: string) {
public async readAndAddFromRssFeedString(feedStringArg: string) {
const smartfeedInstance = new plugins.smartfeed.Smartfeed();
const parsedFeed = await smartfeedInstance.parseFeedFromString(feedStringArg);
this.items = this.items.concat(parsedFeed.items);
}
public async readAndAddFromRssFeedUrl(urlArg: string) {
const smartfeedInstance = new plugins.smartfeed.Smartfeed();
const parsedFeed = await smartfeedInstance.parseFeedFromUrl(urlArg);
this.items = this.items.concat(parsedFeed.items);