Skip to content

Commit

Permalink
fix: replace deprecated beforeDestroy with beforeUnmount
Browse files Browse the repository at this point in the history
  • Loading branch information
emuvente committed Oct 3, 2024
1 parent a428be8 commit 072ddcb
Show file tree
Hide file tree
Showing 42 changed files with 42 additions and 42 deletions.
2 changes: 1 addition & 1 deletion src/components/15Years/15YearsGlobe.vue
Original file line number Diff line number Diff line change
Expand Up @@ -156,7 +156,7 @@ export default {
}
};
},
beforeDestroy() {
beforeUnmount() {
if (this.gkview) {
this.gkview.release();
}
Expand Down
2 changes: 1 addition & 1 deletion src/components/15Years/15YearsLightbox.vue
Original file line number Diff line number Diff line change
Expand Up @@ -110,7 +110,7 @@ export default {
mounted() {
this.isShown = this.visible;
},
beforeDestroy() {
beforeUnmount() {
this.closeLightbox();
},
methods: {
Expand Down
2 changes: 1 addition & 1 deletion src/components/15Years/SwashieFace.vue
Original file line number Diff line number Diff line change
Expand Up @@ -132,7 +132,7 @@ export default {
mounted() {
this.fillErUp();
},
beforeDestroy() {
beforeUnmount() {
clearInterval(this.timer);
this.timer = null;
},
Expand Down
2 changes: 1 addition & 1 deletion src/components/BorrowerProfile/CommentsAndWhySpecial.vue
Original file line number Diff line number Diff line change
Expand Up @@ -429,7 +429,7 @@ export default {
window.addEventListener('resize', this.throttledResize);
this.determineIfMobile();
},
beforeDestroy() {
beforeUnmount() {
this.destroyObserver();
window.removeEventListener('resize', this.throttledResize);
},
Expand Down
2 changes: 1 addition & 1 deletion src/components/BorrowerProfile/CountryInfo.vue
Original file line number Diff line number Diff line change
Expand Up @@ -184,7 +184,7 @@ export default {
mounted() {
this.createObserver();
},
beforeDestroy() {
beforeUnmount() {
this.destroyObserver();
},
};
Expand Down
2 changes: 1 addition & 1 deletion src/components/BorrowerProfile/FundedBorrowerProfile.vue
Original file line number Diff line number Diff line change
Expand Up @@ -395,7 +395,7 @@ export default {
}
},
},
beforeDestroy() {
beforeUnmount() {
this.destroyViewportObserver();
},
};
Expand Down
2 changes: 1 addition & 1 deletion src/components/BorrowerProfile/JournalUpdates.vue
Original file line number Diff line number Diff line change
Expand Up @@ -182,7 +182,7 @@ export default {
mounted() {
this.createObserver();
},
beforeDestroy() {
beforeUnmount() {
this.destroyObserver();
},
};
Expand Down
2 changes: 1 addition & 1 deletion src/components/BorrowerProfile/LendCta.vue
Original file line number Diff line number Diff line change
Expand Up @@ -873,7 +873,7 @@ export default {
mounted() {
this.createWrapperObserver();
},
beforeDestroy() {
beforeUnmount() {
this.destroyWrapperObserver();
},
};
Expand Down
2 changes: 1 addition & 1 deletion src/components/BorrowerProfile/LendersAndTeams.vue
Original file line number Diff line number Diff line change
Expand Up @@ -416,7 +416,7 @@ export default {
this.createObserver();
this.gatherCurrentUserData();
},
beforeDestroy() {
beforeUnmount() {
this.destroyObserver();
},
};
Expand Down
2 changes: 1 addition & 1 deletion src/components/BorrowerProfile/MoreAboutLoan.vue
Original file line number Diff line number Diff line change
Expand Up @@ -253,7 +253,7 @@ export default {
mounted() {
this.createObserver();
},
beforeDestroy() {
beforeUnmount() {
this.destroyObserver();
},
};
Expand Down
2 changes: 1 addition & 1 deletion src/components/BorrowerProfile/SupporterDetails.vue
Original file line number Diff line number Diff line change
Expand Up @@ -213,7 +213,7 @@ export default {
this.isMobile = document.documentElement.clientWidth < 735;
},
},
beforeDestroy() {
beforeUnmount() {
window.removeEventListener('resize', _throttle(() => {
this.determineIfMobile();
}, 200));
Expand Down
2 changes: 1 addition & 1 deletion src/components/BorrowerProfile/WhySpecial.vue
Original file line number Diff line number Diff line change
Expand Up @@ -113,7 +113,7 @@ export default {
mounted() {
this.createObserver();
},
beforeDestroy() {
beforeUnmount() {
this.destroyObserver();
},
};
Expand Down
2 changes: 1 addition & 1 deletion src/components/Checkout/EmptyBasketCarousel.vue
Original file line number Diff line number Diff line change
Expand Up @@ -119,7 +119,7 @@ export default {
// we're doing this all client side
this.loadLoans();
},
beforeDestroy() {
beforeUnmount() {
window.removeEventListener('resize', this.handleResize);
}
};
Expand Down
2 changes: 1 addition & 1 deletion src/components/Checkout/LoanReservation.vue
Original file line number Diff line number Diff line change
Expand Up @@ -135,7 +135,7 @@ export default {
mounted() {
this.activateReservationTimer();
},
beforeDestroy() {
beforeUnmount() {
if (this.reservationMessageId) {
clearInterval(this.reservationMessageId);
}
Expand Down
2 changes: 1 addition & 1 deletion src/components/Kv/KvCarousel.vue
Original file line number Diff line number Diff line change
Expand Up @@ -251,7 +251,7 @@ export default {
this.$emit('change', this.currentIndex);
});
},
beforeDestroy() {
beforeUnmount() {
if (this.autoplay) {
clearInterval(this.intervalTimer);
}
Expand Down
2 changes: 1 addition & 1 deletion src/components/Kv/KvDropdown.vue
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ export default {
this.popper.scheduleUpdate();
}
},
beforeDestroy() {
beforeUnmount() {
this.unmakeDropdown();
},
methods: {
Expand Down
2 changes: 1 addition & 1 deletion src/components/Kv/KvLightbox.vue
Original file line number Diff line number Diff line change
Expand Up @@ -128,7 +128,7 @@ export default {
this.isShown = this.visible;
this.init();
},
beforeDestroy() {
beforeUnmount() {
this.closeLightbox();
},
methods: {
Expand Down
2 changes: 1 addition & 1 deletion src/components/Kv/KvMap.vue
Original file line number Diff line number Diff line change
Expand Up @@ -309,7 +309,7 @@ export default {
}
},
},
beforeDestroy() {
beforeUnmount() {
if (this.mapInstance) {
if (!this.hasWebGL && !this.leafletReady) {
// turn off the leaflet instance
Expand Down
2 changes: 1 addition & 1 deletion src/components/Kv/KvPopper.vue
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ export default {
this.popper.scheduleUpdate();
}
},
beforeDestroy() {
beforeUnmount() {
this.removeEvents();
if (this.popper) {
this.popper.destroy();
Expand Down
2 changes: 1 addition & 1 deletion src/components/Kv/KvSelectBox.vue
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,7 @@ export default {
document.addEventListener('click', this.clickDocument);
document.addEventListener('touchstart', this.clickDocument);
},
beforeDestroy() {
beforeUnmount() {
document.removeEventListener('click', this.clickDocument);
document.removeEventListener('touchstart', this.clickDocument);
Expand Down
2 changes: 1 addition & 1 deletion src/components/Lend/LoanSearch/LoanSearchFilterChips.vue
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ export default {
window.addEventListener('resize', this.throttledDetermineIsCollapsable);
},
beforeDestroy() {
beforeUnmount() {
window.removeEventListener('resize', this.throttledDetermineIsCollapsable);
},
computed: {
Expand Down
2 changes: 1 addition & 1 deletion src/components/LoanCards/KivaClassicBasicLoanCard.vue
Original file line number Diff line number Diff line change
Expand Up @@ -588,7 +588,7 @@ export default {
this.createViewportObserver();
}
},
beforeDestroy() {
beforeUnmount() {
this.destroyViewportObserver();
this.watchedQuery.subscription?.unsubscribe();
},
Expand Down
2 changes: 1 addition & 1 deletion src/components/LoanCards/KvClassicLoanCardContainer.vue
Original file line number Diff line number Diff line change
Expand Up @@ -494,7 +494,7 @@ export default {
this.fetchLoanActivity();
}
},
beforeDestroy() {
beforeUnmount() {
this.destroyViewportObserver();
this.watchedQuery.subscription?.unsubscribe();
},
Expand Down
2 changes: 1 addition & 1 deletion src/components/LoanCards/NewHomePageLoanCard.vue
Original file line number Diff line number Diff line change
Expand Up @@ -365,7 +365,7 @@ export default {
this.createViewportObserver();
}
},
beforeDestroy() {
beforeUnmount() {
this.destroyViewportObserver();
},
watch: {
Expand Down
2 changes: 1 addition & 1 deletion src/components/LoanFinding/LendingCategorySection.vue
Original file line number Diff line number Diff line change
Expand Up @@ -171,7 +171,7 @@ export default {
mounted() {
window.addEventListener('resize', this.handleResize);
},
beforeDestroy() {
beforeUnmount() {
window.removeEventListener('resize', this.handleResize);
}
};
Expand Down
2 changes: 1 addition & 1 deletion src/components/LoansYouMightLike/LymlContainer.vue
Original file line number Diff line number Diff line change
Expand Up @@ -194,7 +194,7 @@ export default {
this.saveWindowWidth();
});
},
beforeDestroy() {
beforeUnmount() {
window.removeEventListener('resize', this.throttledResize());
},
methods: {
Expand Down
2 changes: 1 addition & 1 deletion src/components/MonthlyGood/MonthlyGoodSelectorDesktop.vue
Original file line number Diff line number Diff line change
Expand Up @@ -184,7 +184,7 @@ export default {
mounted() {
document.addEventListener('keyup', this.onKeyUp);
},
beforeDestroy() {
beforeUnmount() {
document.removeEventListener('keyup', this.onKeyUp);
},
methods: {
Expand Down
2 changes: 1 addition & 1 deletion src/components/MonthlyGood/MonthlyGoodSelectorWrapper.vue
Original file line number Diff line number Diff line change
Expand Up @@ -165,7 +165,7 @@ export default {
this.mgStickBarOffset = offsetHeight;
}
},
beforeDestroy() {
beforeUnmount() {
window.removeEventListener('scroll', this.throttledScroll);
window.removeEventListener('scroll', () => {
this.hasScrolled = true;
Expand Down
2 changes: 1 addition & 1 deletion src/components/Settings/AppAuthentication.vue
Original file line number Diff line number Diff line change
Expand Up @@ -162,7 +162,7 @@ export default {
mounted() {
this.startEnrollment();
},
beforeDestroy() {
beforeUnmount() {
this.lightboxVisible = false;
},
methods: {
Expand Down
2 changes: 1 addition & 1 deletion src/components/Settings/PhoneAuthentication.vue
Original file line number Diff line number Diff line change
Expand Up @@ -221,7 +221,7 @@ export default {
return 'Phone number';
},
},
beforeDestroy() {
beforeUnmount() {
this.lightboxVisible = false;
},
methods: {
Expand Down
2 changes: 1 addition & 1 deletion src/components/Settings/SubscriptionsSettingsCards.vue
Original file line number Diff line number Diff line change
Expand Up @@ -140,7 +140,7 @@ export default {
mounted() {
window.addEventListener('beforeunload', this.onLeave);
},
beforeDestroy() {
beforeUnmount() {
window.removeEventListener('beforeunload', this.onLeave);
},
methods: {
Expand Down
2 changes: 1 addition & 1 deletion src/components/Thanks/ThanksLayoutV2.vue
Original file line number Diff line number Diff line change
Expand Up @@ -391,7 +391,7 @@ export default {
return this.visibleSection === 'share';
}
},
beforeDestroy() {
beforeUnmount() {
window.removeEventListener('resize', _throttle(() => {
this.determineIfMobile();
}, 200));
Expand Down
2 changes: 1 addition & 1 deletion src/components/WwwFrame/TheHeader.vue
Original file line number Diff line number Diff line change
Expand Up @@ -889,7 +889,7 @@ export default {
});
window.addEventListener('resize', this.determineIfMobile());
},
beforeDestroy() {
beforeUnmount() {
window.removeEventListener('resize', this.determineIfMobile());
},
methods: {
Expand Down
2 changes: 1 addition & 1 deletion src/components/WwwFrame/WwwPageDesign.vue
Original file line number Diff line number Diff line change
Expand Up @@ -283,7 +283,7 @@ This is a message requesting the Kiva Post Grot typekit for the purpose(s) of
mounted() {
this.createObserver();
},
beforeDestroy() {
beforeUnmount() {
this.destroyObserver();
},
};
Expand Down
2 changes: 1 addition & 1 deletion src/pages/Autolending/AutolendingSettingsPage.vue
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,7 @@ export default {
mounted() {
window.addEventListener('beforeunload', this.onLeave);
},
beforeDestroy() {
beforeUnmount() {
window.removeEventListener('beforeunload', this.onLeave);
},
methods: {
Expand Down
2 changes: 1 addition & 1 deletion src/pages/Autolending/InlineCounter.vue
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,7 @@ export default {
window.addEventListener('resize', this.throttledResize);
window.addEventListener('scroll', this.throttledScroll);
},
beforeDestroy() {
beforeUnmount() {
window.removeEventListener('resize', this.throttledResize);
window.removeEventListener('scroll', this.throttledScroll);
},
Expand Down
2 changes: 1 addition & 1 deletion src/pages/BorrowerProfile/BorrowerProfile.vue
Original file line number Diff line number Diff line change
Expand Up @@ -668,7 +668,7 @@ export default {
this.isMobile = document.documentElement.clientWidth < 735;
},
},
beforeDestroy() {
beforeUnmount() {
window.removeEventListener('resize', _throttle(() => {
this.determineIfMobile();
}, 200));
Expand Down
2 changes: 1 addition & 1 deletion src/pages/LandingPages/CorporateCampaign/CCLandingPage.vue
Original file line number Diff line number Diff line change
Expand Up @@ -738,7 +738,7 @@ export default {

this.setAuthStatus(this.kvAuth0?.user ?? {});
},
beforeDestroy() {
beforeUnmount() {
clearInterval(this.currentTimeInterval);
},
watch: {
Expand Down
2 changes: 1 addition & 1 deletion src/pages/LandingPages/Unbounce/IFrameEmbed.vue
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,7 @@ export default {
oneTrustGlobalEvent();
}
},
beforeDestroy() {
beforeUnmount() {
window.removeEventListener('oneTrustAccepted', this.handleOneTrustAccepted);
window.removeEventListener('resize', _throttle(() => {
Expand Down
2 changes: 1 addition & 1 deletion src/pages/LendingTeams/TeamLeaderboard.vue
Original file line number Diff line number Diff line change
Expand Up @@ -209,7 +209,7 @@ export default {
this.determineIfMobile();
window.addEventListener('resize', this.throttledResize);
},
beforeDestroy() {
beforeUnmount() {
window.removeEventListener('resize', this.throttledResize);
},
};
Expand Down
2 changes: 1 addition & 1 deletion src/pages/LoanFinding/LoanFinding.vue
Original file line number Diff line number Diff line change
Expand Up @@ -503,7 +503,7 @@ export default {
'EXP-VUE-FLSS-Ongoing-Sitewide'
);
},
beforeDestroy() {
beforeUnmount() {
this.destroySpotlightViewportObserver();
},
};
Expand Down
2 changes: 1 addition & 1 deletion src/plugins/delay-until-visible-mixin.js
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ export default {
}
}
},
beforeDestroy() {
beforeUnmount() {
if (this.delayUntilVisibleObserver) {
this.delayUntilVisibleObserver.disconnect();
}
Expand Down

0 comments on commit 072ddcb

Please sign in to comment.