Make the shouldRender return type more explicit

This commit is contained in:
Mészáros Róbert 2020-04-09 15:00:51 +03:00
parent a01866549c
commit 36ca26d27d
4 changed files with 4 additions and 4 deletions

View file

@ -21,7 +21,7 @@ class CartBootstrap {
}
shouldRender() {
return document.querySelector(this.gateway.button.wrapper);
return document.querySelector(this.gateway.button.wrapper) !== null;
}
}

View file

@ -49,7 +49,7 @@ class CheckoutBootstap {
return false;
}
return document.querySelector(this.gateway.button.wrapper);
return document.querySelector(this.gateway.button.wrapper) !== null;
}
}

View file

@ -22,7 +22,7 @@ class MiniCartBootstap {
}
shouldRender() {
return document.querySelector(this.gateway.button.mini_cart_wrapper);
return document.querySelector(this.gateway.button.mini_cart_wrapper) !== null;
}
}

View file

@ -43,7 +43,7 @@ class SingleProductBootstap {
return false;
}
return document.querySelector(this.gateway.button.wrapper);
return document.querySelector(this.gateway.button.wrapper) !== null;
}
}