| @@ -365,9 +365,11 @@ | ||
| 365 | 365 | * @since v.1.0.0 |
| 366 | 366 | * @return void No return value. |
| 367 | 367 | */ |
| 368 | 368 | public function register_option_panel_scripts_callback() { |
| 369 | - $is_active = ultimate_post()->is_lc_active(); | |
| 369 | + $is_active = ultimate_post()->is_lc_active(); | |
| 370 | + $is_expired = Xpo::is_lc_expired(); | |
| 371 | + | |
| 370 | 372 | $license_key = Xpo::get_lc_key(); |
| 371 | 373 | $_page = isset($_GET['page']) ? sanitize_text_field($_GET['page']) : ''; // @codingStandardsIgnoreLine |
| 372 | 374 | $post_type = get_post_type(); |
| 373 | 375 | $is_woocommerce_active = class_exists( 'WooCommerce' ) ? true : false; |
| @@ -383,8 +385,9 @@ | ||
| 383 | 385 | array( |
| 384 | 386 | 'url' => ULTP_URL, |
| 385 | 387 | 'version' => ULTP_VER, |
| 386 | 388 | 'active' => $is_active, |
| 389 | + 'expierd' => $is_expired, | |
| 387 | 390 | 'security' => wp_create_nonce( 'ultp-nonce' ), |
| 388 | 391 | 'ajax' => admin_url( 'admin-ajax.php' ), |
| 389 | 392 | 'settings' => ultimate_post()->get_setting(), |
| 390 | 393 | 'post_type' => $post_type, |
| @@ -433,8 +436,9 @@ | ||
| 433 | 436 | 'ajax' => admin_url( 'admin-ajax.php' ), |
| 434 | 437 | 'security' => wp_create_nonce( 'ultp-nonce' ), |
| 435 | 438 | 'url' => ULTP_URL, |
| 436 | 439 | 'active' => $is_active, |
| 440 | + 'expierd' => $is_expired, | |
| 437 | 441 | 'license' => $license_key, |
| 438 | 442 | 'settings' => ultimate_post()->get_setting(), |
| 439 | 443 | 'addons_settings' => apply_filters( 'ultp_settings', array() ), |
| 440 | 444 | 'builder_url' => admin_url( 'admin.php?page=ultp-settings#builder' ), |
| @@ -464,8 +468,9 @@ | ||
| 464 | 468 | * @return void No return value. |
| 465 | 469 | */ |
| 466 | 470 | public function register_block_scripts_editor_area() { |
| 467 | 471 | ultimate_post()->register_scripts_common(); |
| 472 | + $is_expired = Xpo::is_lc_expired(); | |
| 468 | 473 | global $pagenow; |
| 469 | 474 | $depends = 'wp-editor'; |
| 470 | 475 | if ( $pagenow === 'widgets.php' ) { |
| 471 | 476 | $depends = 'wp-edit-widgets'; |
| @@ -530,8 +535,9 @@ | ||
| 530 | 535 | 'disable_image_size' => ultimate_post()->get_setting( 'disable_image_size' ), |
| 531 | 536 | 'dark_logo' => get_option( 'ultp_site_dark_logo' ) ? get_option( 'ultp_site_dark_logo' ) : false, |
| 532 | 537 | 'builder_url' => admin_url( 'admin.php?page=ultp-settings#builder' ), |
| 533 | 538 | 'custom_fonts' => $custom_fonts, |
| 539 | + 'expierd' => $is_expired, | |
| 534 | 540 | ) |
| 535 | 541 | ); |
| 536 | 542 | wp_set_script_translations( 'ultp-blocks-editor-script', 'ultimate-post', ULTP_PATH . 'languages/' ); |
| 537 | 543 | } |