DowngradePhp72JsonConstRector
Remove Json constant that available only in php 7.2
-$inDecoder = new Decoder($connection, true, 512, \JSON_INVALID_UTF8_IGNORE);
+$inDecoder = new Decoder($connection, true, 512, 0);
-$inDecoder = new Decoder($connection, true, 512, \JSON_INVALID_UTF8_SUBSTITUTE);
+$inDecoder = new Decoder($connection, true, 512, 0);
Configure your rector.php:
<?php
use Rector\Config\RectorConfig;
use Rector\DowngradePhp72\Rector\ConstFetch\DowngradePhp72JsonConstRector;
return RectorConfig::configure()
->withRules([
DowngradePhp72JsonConstRector::class,
]);