Improved working on new post

This commit is contained in:
Daniel Hüsken 2024-12-20 11:37:29 +01:00
parent af08ad5fce
commit a431b52094
No known key found for this signature in database
GPG key ID: 9F732DA37FA709E8
2 changed files with 29 additions and 19 deletions

View file

@ -71,9 +71,6 @@ document.addEventListener( 'DOMContentLoaded', () => {
};
const checkSubscriptionPeriodsInterval = (period, period_interval, linkBtn) => {
if ( ! linkBtn) {
return;
}
if (
( period === 'year' && parseInt( period_interval ) > 1 ) ||
( period === 'month' && parseInt( period_interval ) > 12 ) ||
@ -82,7 +79,7 @@ document.addEventListener( 'DOMContentLoaded', () => {
) {
linkBtn.disabled = true;
linkBtn.checked = false;
linkBtn.setAttribute('title', __( 'Not allowed period intervall combination!', 'woocommerce-paypal-subscriptions' ) );
linkBtn.setAttribute('title', __( 'Not allowed period intervall combination for PayPal Subscriptions!', 'woocommerce-paypal-subscriptions' ) );
} else {
linkBtn.disabled = false;
linkBtn.removeAttribute('title');