Fix #20608: Fix @return annotations for yii\rest\Serializer methods

This commit is contained in:
Maksim Spirkov
2025-10-14 19:30:50 +03:00
committed by GitHub
parent 33bcf7fffa
commit e6bc2ca0ff
2 changed files with 3 additions and 2 deletions

View File

@@ -56,6 +56,7 @@ Yii Framework 2 Change Log
- Bug #20595: Fix `@return` annotation for `BaseHtml::getAttributeValue()` (mspirkov) - Bug #20595: Fix `@return` annotation for `BaseHtml::getAttributeValue()` (mspirkov)
- Bug #20604: Fix `@var` annotation for `yii\db\Command::$pdoStatement` (mspirkov) - Bug #20604: Fix `@var` annotation for `yii\db\Command::$pdoStatement` (mspirkov)
- Bug #20600: Fix `@var` annotation for `yii\test\FileFixtureTrait::$dataFile` (mspirkov) - Bug #20600: Fix `@var` annotation for `yii\test\FileFixtureTrait::$dataFile` (mspirkov)
- Bug #20608: Fix `@return` annotations for `yii\rest\Serializer` methods (mspirkov)
- Bug #20610: Fix `@var` annotation for `ActiveQueryTrait::$with` (mspirkov) - Bug #20610: Fix `@var` annotation for `ActiveQueryTrait::$with` (mspirkov)
- Bug #20611: Fix `@return` annotations for `yii\i18n\GettextMoFile` methods (mspirkov) - Bug #20611: Fix `@return` annotations for `yii\i18n\GettextMoFile` methods (mspirkov)

View File

@@ -184,7 +184,7 @@ class Serializer extends Component
/** /**
* Serializes a data provider. * Serializes a data provider.
* @param DataProviderInterface $dataProvider * @param DataProviderInterface $dataProvider
* @return array the array representation of the data provider. * @return array|null the array representation of the data provider.
*/ */
protected function serializeDataProvider($dataProvider) protected function serializeDataProvider($dataProvider)
{ {
@@ -256,7 +256,7 @@ class Serializer extends Component
/** /**
* Serializes a model object. * Serializes a model object.
* @param Arrayable $model * @param Arrayable $model
* @return array the array representation of the model * @return array|null the array representation of the model
*/ */
protected function serializeModel($model) protected function serializeModel($model)
{ {