init_execution_time(); // compatible. return static::$exec_start; } /** * Method get_exec_time(). * * Get execution time start value. */ public function get_exec_time() { if ( null === static::$exec_start ) { static::$exec_start = microtime( true ); } $sec = microtime( true ) - static::$exec_start; // seconds. MainWP_Logger::instance()->log_action( 'execution time :: [value=' . round( $sec, 4 ) . '](seconds)', MainWP_Logger::EXECUTION_TIME_LOG_PRIORITY ); return $sec; } }