Skip to content

Commit f17a6e3

Browse files
authored
fix
1 parent 50afc9c commit f17a6e3

File tree

1 file changed

+1
-19
lines changed

1 file changed

+1
-19
lines changed

src/Console/ModelsCommand.php

Lines changed: 1 addition & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -902,24 +902,6 @@ protected function createPhpDocs($class)
902902
$serializer = new DocBlockSerializer();
903903
$docComment = $serializer->getDocComment($phpdoc);
904904

905-
if ($this->write_mixin) {
906-
$phpdocMixin = new DocBlock($reflection, new Context($namespace));
907-
// remove all mixin tags prefixed with IdeHelper
908-
foreach ($phpdocMixin->getTagsByName('mixin') as $tag) {
909-
if (Str::startsWith($tag->getContent(), 'IdeHelper')) {
910-
$phpdocMixin->deleteTag($tag);
911-
}
912-
}
913-
914-
$mixinClassName = "IdeHelper{$classname}";
915-
$phpdocMixin->appendTag(Tag::createInstance("@mixin {$mixinClassName}", $phpdocMixin));
916-
$mixinDocComment = $serializer->getDocComment($phpdocMixin);
917-
// remove blank lines if there's no text
918-
if (!$phpdocMixin->getText()) {
919-
$mixinDocComment = preg_replace("/\s\*\s*\n/", '', $mixinDocComment);
920-
}
921-
}
922-
923905
if ($this->write) {
924906
$modelDocComment = $this->write_mixin ? $mixinDocComment : $docComment;
925907
$filename = $reflection->getFileName();
@@ -939,7 +921,7 @@ protected function createPhpDocs($class)
939921
}
940922

941923
if ($this->write_mixin) {
942-
return "namespace {$namespace}{\n{$docComment}\n\t{$keyword}class {$classname} {}\n}\n\n ";
924+
return "namespace {$namespace}{\n{$docComment}\n\t{$keyword}class IdeHelper{$classname} {}\n}\n\n ";
943925
}
944926

945927
$output = "namespace {$namespace}{\n{$docComment}\n\t{$keyword}class {$className} extends \Eloquent ";

0 commit comments

Comments
 (0)