Skip to content

Commit

Permalink
change the if/else for regex,prefix,postfix to an if statement so the…
Browse files Browse the repository at this point in the history
…y may all be used
  • Loading branch information
dennyreiter committed Jul 10, 2019
1 parent 91e62c9 commit 21ab000
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions list-card.js
Original file line number Diff line number Diff line change
Expand Up @@ -160,9 +160,11 @@ class ListCard extends HTMLElement {

if (columns[column].hasOwnProperty('regex')) {
newText = new RegExp(columns[column].regex).exec(feed[entry][columns[column].field]);
} else if (columns[column].hasOwnProperty('prefix')) {
}
if (columns[column].hasOwnProperty('prefix')) {
newText = columns[column].prefix + newText;
} else if (columns[column].hasOwnProperty('postfix')) {
}
if (columns[column].hasOwnProperty('postfix')) {
newText += columns[column].postfix;
}

Expand Down

0 comments on commit 21ab000

Please sign in to comment.