appengine-php-sdk
appengine-php-sdk copied to clipboard
Make CloudStorageTools::createUploadUrl compatible with PHP7
createUploadUrl
calls getUploadMaxFileSizeInBytes
, which does the following operation on a mostly-numeric string:
$val *= 1024
In PHP5, this works fine, because non-numeric values are stripped from the end.
In PHP7, a warning is issued which states A non well formed numeric value encountered
.
The value has a final non-numeric character which can be stripped to prevent this warning.
This will continue to function in PHP5 as well.
Fixes #10
Other changes were necessary simply to get the build to pass.
Coverage increased (+1.0%) to 11.123% when pulling 070f50318f91ed0db9fff014848fbb9f7eaec6cb on goodevilgenius:upload-max-size-php7 into 6bdf4bcb638782526a6969aa36528ac583cbc3da on GoogleCloudPlatform:master.
I'm currently facing this issue, may I know what the status is for it?