Merge pull request #687 from fewieden/develop

bugfix newsfeed
This commit is contained in:
Michael Teeuw 2017-02-07 12:04:00 +01:00 committed by GitHub
commit 1fe95a5fe4
2 changed files with 3 additions and 2 deletions

View File

@ -51,6 +51,7 @@ This project adheres to [Semantic Versioning](http://semver.org/).
- If units is set to imperial, the showRainAmount option of weatherforecast will show the correct unit. - If units is set to imperial, the showRainAmount option of weatherforecast will show the correct unit.
- Module currentWeather: check if temperature received from api is defined. - Module currentWeather: check if temperature received from api is defined.
- Fix an issue with module hidden status changing to `true` although lock string prevented showing it - Fix an issue with module hidden status changing to `true` although lock string prevented showing it
- Fix newsfeed module bug (removeStartTags)
## [2.1.0] - 2016-12-31 ## [2.1.0] - 2016-12-31

View File

@ -112,7 +112,7 @@ Module.register("newsfeed",{
//Remove selected tags from the beginning of rss feed items (title or description) //Remove selected tags from the beginning of rss feed items (title or description)
if (this.config.removeStartTags == "title" || "both") { if (this.config.removeStartTags == "title" || this.config.removeStartTags == "both") {
for (f=0; f<this.config.startTags.length;f++) { for (f=0; f<this.config.startTags.length;f++) {
if (this.newsItems[this.activeItem].title.slice(0,this.config.startTags[f].length) == this.config.startTags[f]) { if (this.newsItems[this.activeItem].title.slice(0,this.config.startTags[f].length) == this.config.startTags[f]) {
@ -122,7 +122,7 @@ Module.register("newsfeed",{
} }
if (this.config.removeStartTags == "description" || "both") { if (this.config.removeStartTags == "description" || this.config.removeStartTags == "both") {
if (this.config.showDescription) { if (this.config.showDescription) {
for (f=0; f<this.config.startTags.length;f++) { for (f=0; f<this.config.startTags.length;f++) {