Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Deprecate polyfill function array_replace() #9056

Merged
merged 3 commits into from May 16, 2018
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
3 changes: 3 additions & 0 deletions classes/Tools.php
Expand Up @@ -784,9 +784,12 @@ public static function convertPrice($price, $currency = null, $to_currency = tru
* Implement array_replace for PHP <= 5.2
*
* @return array|mixed|null
*
* @deprecated since version 1.7.4.0, to be removed.
*/
public static function array_replace()
{
Tools::displayAsDeprecated('Use PHP\'s array_replace() instead');
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍

if (!function_exists('array_replace')) {
$args = func_get_args();
$num_args = func_num_args();
Expand Down