updating for feed saving
This commit is contained in:
@@ -14,7 +14,8 @@ module.exports = {
|
||||
|
||||
libFlayer.addSource(title,link);
|
||||
message.reply(`Adding ${title} to the list of RSS sources`);
|
||||
libFlayer.writeFeed();
|
||||
var sources = libFlayer.getSources();
|
||||
libFlayer.writeFeed(sources);
|
||||
libFlayer.loadFeeds();
|
||||
|
||||
},
|
||||
|
||||
@@ -13,6 +13,12 @@ exports.addSource = function(title,source){
|
||||
title: `${title}`,
|
||||
link: `${source}`
|
||||
}
|
||||
|
||||
for (i=0; i<feeds.length; i++){
|
||||
if (feeds[i].link == source){
|
||||
return;
|
||||
}
|
||||
}
|
||||
feeds.push(linkData);
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user