public/wordpress/wp-content/plugins/wp-courseware/includes/core/license.php
/**
	 * Check License Status.
	 *
	 * @since 4.1.0
	 *
	 * @return string $status The status of the license.
	 */
Check License Status.

@return string $status The status of the license.
Check License Status . @return string $status The status of the license .
public function check_status() {
		global $pagenow;
		if ( false === ( $status = get_transient( $this->cache['status'] ) ) ) {
			$license_status = $this->api_request( 'check_license' );
			if ( is_wp_error( $license_status ) ) {
				$status = 'invalid';
			} else {
				$status = $license_status->license;
			}
			$this->cache_status( $status );
		}
		if ( 'invalid' !== $status && ! $this->get_key() ) {
			$this->clear_cache();
		}
		if ( 'invalid' === $status ) {
			$error = sprintf( __( 'Your <strong>WP Courseware</strong> license key is missing or invalid. <a href="%1$s">Please enter your license key.</a>', 'wp-courseware' ), $this->get_license_page() );
			wpcw_display_admin_notice( $error, 'error' );
		}
	}
public function check_status ( ) { global $ pagenow ; if ( false === ( $ status = get_transient ( $ this -> cache [ 'status' ] ) ) ) { $ license_status = $ this -> api_request ( 'check_license' ) ; if ( is_wp_error ( $ license_status ) ) { $ status = 'invalid' ; } else { $ status = $ license_status -> license ; } $ this -> cache_status ( $ status ) ; } if ( 'invalid' !== $ status && ! $ this -> get_key ( ) ) { $ this -> clear_cache ( ) ; } if ( 'invalid' === $ status ) { $ error = sprintf ( __ ( 'Your <strong>WP Courseware</strong> license key is missing or invalid. <a href="%1$s">Please enter your license key.</a>' , 'wp-courseware' ) , $ this -> get_license_page ( ) ) ; wpcw_display_admin_notice ( $ error , 'error' ) ; } }
Check License Status.
Check License Status .
/* translators: %1$s - License page url */