Skip to content

Commit c246f19

Browse files
committed
type fixes
1 parent 6026d26 commit c246f19

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

src/PhpGenerator/ClassType.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@ final class ClassType
5151
/** @var string[] */
5252
private $implements = [];
5353

54-
/** @var string[] */
54+
/** @var array[] */
5555
private $traits = [];
5656

5757
/** @var Constant[] name => Constant */

src/PhpGenerator/Method.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -89,7 +89,7 @@ public function setBody($code, array $args = null): self
8989
$code = null;
9090
trigger_error(__METHOD__ . '() use null instead of false', E_USER_DEPRECATED);
9191
}
92-
$this->body = $args === null ? $code : Helpers::formatArgs($code, $args);
92+
$this->body = $args === null || $code === null ? $code : Helpers::formatArgs($code, $args);
9393
return $this;
9494
}
9595

0 commit comments

Comments
 (0)