refactor(all): strict boolean conditions

This commit is contained in:
Manu Mtz.-Almeida
2018-08-31 18:59:09 +02:00
parent f383ebdf13
commit ba2230510e
96 changed files with 990 additions and 962 deletions

View File

@ -36,7 +36,7 @@ export class Segment {
/**
* the value of the segment.
*/
@Prop({ mutable: true }) value?: string;
@Prop({ mutable: true }) value?: string | null;
@Watch('value')
protected valueChanged(value: string | undefined) {
@ -56,7 +56,7 @@ export class Segment {
}
componentDidLoad() {
if (this.value === undefined) {
if (this.value == null) {
const checked = this.getButtons().find(b => b.checked);
if (checked) {
this.value = checked.value;