diff --git a/Mapping/Caser.php b/Mapping/Caser.php index 6a0022ae..85427a85 100644 --- a/Mapping/Caser.php +++ b/Mapping/Caser.php @@ -11,7 +11,7 @@ namespace ONGR\ElasticsearchBundle\Mapping; -use Doctrine\Common\Inflector\Inflector; +use Doctrine\Inflector\InflectorFactory; /** * Utility for string case transformations. @@ -27,7 +27,7 @@ class Caser */ public static function camel($string) { - return Inflector::camelize($string); + return InflectorFactory::create()->build()->camelize($string); } /** diff --git a/composer.json b/composer.json index defe1790..62752e90 100644 --- a/composer.json +++ b/composer.json @@ -22,7 +22,7 @@ "symfony/property-access": "^4.4|^5.0", "doctrine/annotations": "^1.6", "doctrine/cache": "^1.7", - "doctrine/inflector": "^1.3", + "doctrine/inflector": "^1.4 || ^2.0", "doctrine/collections": "^1.5", "monolog/monolog": "^1.24", "elasticsearch/elasticsearch": "^6.0",