Skip to content

Commit 643580b

Browse files
committed
fix error if not doc on controller action
1 parent f63f10f commit 643580b

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

src/Controller.php

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -349,7 +349,10 @@ final public function showCommandList(): void
349349
continue;
350350
}
351351

352-
$desc = PhpDoc::firstLine($m->getDocComment()) ?: $defaultDes;
352+
$desc = $defaultDes;
353+
if ($phpDoc = $m->getDocComment()) {
354+
$desc = PhpDoc::firstLine($phpDoc);
355+
}
353356

354357
// is a annotation tag
355358
if (strpos($desc, '@') === 0) {

0 commit comments

Comments
 (0)