From 2ae2e008feb98c6ce0c2fc1f72a2e0d2a08b2fd8 Mon Sep 17 00:00:00 2001 From: Ivan Pidikseev Date: Thu, 16 Apr 2020 14:24:25 +0300 Subject: [PATCH] Exception message fix for array properties --- PropertyDescriber/ArrayPropertyDescriber.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/PropertyDescriber/ArrayPropertyDescriber.php b/PropertyDescriber/ArrayPropertyDescriber.php index 1882d7f..7055df4 100644 --- a/PropertyDescriber/ArrayPropertyDescriber.php +++ b/PropertyDescriber/ArrayPropertyDescriber.php @@ -32,7 +32,7 @@ class ArrayPropertyDescriber implements PropertyDescriberInterface, ModelRegistr { $type = $type->getCollectionValueType(); if (null === $type) { - throw new \LogicException(sprintf('Property "%s:%s" is an array, but its items type isn\'t specified. You can specify that by using the type `string[]` for instance or `@SWG\Property(type="array", @SWG\Items(type="string"))`.', $class, $propertyName)); + throw new \LogicException(sprintf('Property "%s" is an array, but its items type isn\'t specified. You can specify that by using the type `string[]` for instance or `@SWG\Property(type="array", @SWG\Items(type="string"))`.', $property->getTitle())); } $property->setType('array');