Slight logic refactor
This commit is contained in:
parent
0fa12ca01c
commit
9c417e1c1b
1 changed files with 7 additions and 8 deletions
|
|
@ -25,12 +25,7 @@ export default {
|
|||
},
|
||||
computed: {
|
||||
displayContent() {
|
||||
let linesToDisplay = [];
|
||||
if (this.hasWindshieldDamage) {
|
||||
linesToDisplay.push(this.windshieldString);
|
||||
}
|
||||
|
||||
return linesToDisplay;
|
||||
return [...this.windshieldCopy];
|
||||
},
|
||||
hasWindshieldDamage() {
|
||||
return (
|
||||
|
|
@ -40,8 +35,12 @@ export default {
|
|||
)
|
||||
);
|
||||
},
|
||||
windshieldString() {
|
||||
return this.getCmsContent("WindshieldDamageWidget", "Text");
|
||||
windshieldCopy() {
|
||||
if (this.hasWindshieldDamage) {
|
||||
return [this.getCmsContent("WindshieldDamageWidget", "Text")];
|
||||
} else {
|
||||
return [];
|
||||
}
|
||||
},
|
||||
},
|
||||
components: {
|
||||
|
|
|
|||
Loading…
Reference in a new issue