Merge pull request #21557 from jdeeburke/fix-memory-limit-byte-values

Fix some memory limit values not correctly converting to bytes
This commit is contained in:
Claudiu Lodromanean 2018-10-15 09:17:27 -07:00 committed by GitHub
commit e4796cfa75
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 2 additions and 2 deletions

View File

@ -146,10 +146,10 @@ abstract class WC_Background_Process extends WP_Background_Process {
if ( ! $memory_limit || -1 === intval( $memory_limit ) ) { if ( ! $memory_limit || -1 === intval( $memory_limit ) ) {
// Unlimited, set to 32GB. // Unlimited, set to 32GB.
$memory_limit = '32000M'; $memory_limit = '32G';
} }
return intval( $memory_limit ) * 1024 * 1024; return wp_convert_hr_to_bytes( $memory_limit );
} }
/** /**