From 4332644adfdbb4367afc46d906a156fb061e01ee Mon Sep 17 00:00:00 2001 From: Jordan Pickwell Date: Fri, 11 Sep 2020 14:44:29 -0500 Subject: [PATCH] chore: make requested changes - Added changelog entry. - Removed unnecessary braces around interpolated variable. - Made property type assignment one line. --- CHANGELOG.md | 1 + src/Console/ModelsCommand.php | 5 ++--- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index b77e3f85f..8c8e412f0 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -8,6 +8,7 @@ All notable changes to this project will be documented in this file. ### Added - Fix phpdoc generate for custom cast with parameter [\#986 / artelkr](https://github.com/barryvdh/laravel-ide-helper/pull/986) - Created a possibility to add custom relation type [\#987 / efinder2](https://github.com/barryvdh/laravel-ide-helper/pull/987) +- Add model property types to magic where methods [\#989 / jpickwell](https://github.com/barryvdh/laravel-ide-helper/pull/989) - Added `@see` with macro/mixin definition location to PhpDoc [\#1054 / riesjart](https://github.com/barryvdh/laravel-ide-helper/pull/1054) ### Changed diff --git a/src/Console/ModelsCommand.php b/src/Console/ModelsCommand.php index 900d8ced6..2d71ecbf4 100644 --- a/src/Console/ModelsCommand.php +++ b/src/Console/ModelsCommand.php @@ -505,7 +505,7 @@ protected function getPropertiesFromTable($model) [ empty($truePropertyType) ? '$value' - : "{$truePropertyType} \$value", + : "$truePropertyType \$value", ] ); } @@ -725,8 +725,7 @@ protected function setProperty($name, $type = null, $read = null, $write = null, $this->properties[$name]['comment'] = (string) $comment; } if ($type !== null) { - $this->properties[$name]['type'] = - $this->getTruePropertyType($type, $nullable); + $this->properties[$name]['type'] = $this->getTruePropertyType($type, $nullable); } if ($read !== null) { $this->properties[$name]['read'] = $read;