Merge pull request #484 from Safelite/feature/CSR-563

CSR-563 | Fix console error with mixin function
This commit is contained in:
scottkiener 2022-05-19 14:44:15 -04:00 committed by GitHub
commit 6fb9e23242
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 3 additions and 2 deletions

View file

@ -84,7 +84,7 @@ export default {
},
methods: {
onResize() {
this.paddingHeight = document.querySelector(".footer #infoBox").offsetHeight;
this.paddingHeight = this.getFooterInfoBoxHeight();
},
updateButtonText(newText) {
this.customButtontext = newText;

View file

@ -43,7 +43,8 @@ export default {
}
},
getFooterInfoBoxHeight() {
return document.querySelector(".footer #infoBox").offsetHeight;
const footerInfoBox = document.querySelector(".footer #infoBox");
return footerInfoBox ? footerInfoBox.offsetHeight : 0;
}
},
computed: {