maybe_set_activation_redirect(); $this->maybe_set_activation_time(); } /** * Set initial activation redirect flag. * * @return void */ private function maybe_set_activation_redirect() { $blockart_version = get_option( '_blockart_version' ); if ( empty( $blockart_version ) ) { update_option( '_blockart_activation_redirect', true ); } } /** * Set initial activation time. * * @return void */ private function maybe_set_activation_time() { $activation_time = get_option( '_blockart_activation_time', '' ); if ( empty( $activation_time ) ) { update_option( '_blockart_activation_time', time() ); } } /** * Check version on init. * * @return void */ public function check_version() { if ( ! defined( 'IFRAME_REQUEST' ) && version_compare( get_option( '_blockart_version' ), BLOCKART_VERSION, '<' ) ) { $this->maybe_set_activation_time(); } } }