WC_Background_Process::get_memory_limit()
Get memory limit.
Метод класса: WC_Background_Process{}
Хуков нет.
Возвращает
int
.
Использование
// protected - в коде основоного (родительского) или дочернего класса $result = $this->get_memory_limit();
Код WC_Background_Process::get_memory_limit() WC Background Process::get memory limit WC 8.7.0
protected function get_memory_limit() { if ( function_exists( 'ini_get' ) ) { $memory_limit = ini_get( 'memory_limit' ); } else { // Sensible default. $memory_limit = '128M'; } if ( ! $memory_limit || -1 === intval( $memory_limit ) ) { // Unlimited, set to 32GB. $memory_limit = '32G'; } return wp_convert_hr_to_bytes( $memory_limit ); }