diff --git a/config/ide-helper.php b/config/ide-helper.php index 48a06db..38013a2 100644 --- a/config/ide-helper.php +++ b/config/ide-helper.php @@ -153,13 +153,13 @@ return array( | | For example, normally you would see this: | - | * @property \Carbon\Carbon $created_at - | * @property \Carbon\Carbon $updated_at + | * @property \Illuminate\Support\Carbon $created_at + | * @property \Illuminate\Support\Carbon $updated_at | | With this enabled, the properties will be this: | - | * @property \Carbon\Carbon $createdAt - | * @property \Carbon\Carbon $updatedAt + | * @property \Illuminate\Support\Carbon $createdAt + | * @property \Illuminate\Support\Carbon $updatedAt | | Note, it is currently an all-or-nothing option. | diff --git a/readme.md b/readme.md index 5c83911..640e557 100644 --- a/readme.md +++ b/readme.md @@ -122,8 +122,8 @@ php artisan ide-helper:models Post * @property integer $author_id * @property string $title * @property string $text - * @property \Carbon\Carbon $created_at - * @property \Carbon\Carbon $updated_at + * @property \Illuminate\Support\Carbon $created_at + * @property \Illuminate\Support\Carbon $updated_at * @property-read \User $author * @property-read \Illuminate\Database\Eloquent\Collection|\Comment[] $comments */ diff --git a/src/Console/ModelsCommand.php b/src/Console/ModelsCommand.php index 7edc282..ad575ca 100644 --- a/src/Console/ModelsCommand.php +++ b/src/Console/ModelsCommand.php @@ -283,7 +283,7 @@ class ModelsCommand extends Command break; case 'date': case 'datetime': - $realType = '\Carbon\Carbon'; + $realType = '\Illuminate\Support\Carbon'; break; case 'collection': $realType = '\Illuminate\Support\Collection'; @@ -347,7 +347,7 @@ class ModelsCommand extends Command foreach ($columns as $column) { $name = $column->getName(); if (in_array($name, $model->getDates())) { - $type = '\Carbon\Carbon'; + $type = '\Illuminate\Support\Carbon'; } else { $type = $column->getType()->getName(); switch ($type) {