Browse Source

Fix crash if feed used with articles without links

Didn't realise this was possible...
shorten
benji7425 3 years ago
parent
commit
96def786a4
  1. 4
      CHANGELOG.md
  2. 2
      app/models/feed-data.js

4
CHANGELOG.md

@ -1,5 +1,9 @@
# Changelog
## Unreleased
### Fixed
- Temporary fix for bot crash if used with a feed without links in the articles (didn't realise this was possible...)
## v3.1.3
### Added
- Add rudimentary pagination for viewing feeds when there are more than 10

2
app/models/feed-data.js

@ -74,7 +74,7 @@ module.exports = class FeedData {
return;
}
if (articles.length > 0) {
if (articles.length > 0 && articles[0].link) {
const latest = normaliseUrl(articles[0].link);

Loading…
Cancel
Save