Skip to content

Commit

Permalink
fix: unparseable news (#294)
Browse files Browse the repository at this point in the history
  • Loading branch information
TobiTenno committed Jul 13, 2021
1 parent ddc2efb commit 86c8ab9
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/News.js
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ class News extends WorldstateObject {
* @type {string}
*/
this.link = data.Prop;
if (!this.link || !this.link.length) {
if ((!this.link || !this.link.length) && (data.Links && data.Links.length)) {
this.link = (data.Links.find((l) => l.LanguageCode === locale) || { Link: 'https://www.warframe.com/' }).Link;
}

Expand Down

0 comments on commit 86c8ab9

Please sign in to comment.