File tree Expand file tree Collapse file tree 2 files changed +4
-4
lines changed Expand file tree Collapse file tree 2 files changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -240,7 +240,7 @@ private function generateAttributes(): array
240240 return ['comments ' => [new Doc ($ this ->docBlock ->generate ())]];
241241 }
242242
243- if ($ this ->typed === false || $ this ->docBlockComment || $ this ->returnTypeDocBlockHint ) {
243+ if ($ this ->typed === false || $ this ->docBlockComment !== null || $ this ->returnTypeDocBlockHint !== null ) {
244244 $ docBlock = new DocBlock ($ this ->docBlockComment );
245245
246246 foreach ($ this ->getParameters () as $ parameter ) {
@@ -260,10 +260,10 @@ private function generateAttributes(): array
260260 if ($ this ->returnType ) {
261261 $ returnType = $ this ->returnType ->type ();
262262 }
263- if ($ this ->returnTypeDocBlockHint ) {
263+ if ($ this ->returnTypeDocBlockHint !== null ) {
264264 $ returnType = $ this ->returnTypeDocBlockHint ;
265265 }
266- if ($ returnType ) {
266+ if ($ returnType !== null ) {
267267 $ docBlock ->addTag (new ReturnTag ($ returnType ));
268268 }
269269
Original file line number Diff line number Diff line change @@ -180,7 +180,7 @@ private function generateAttributes(): array
180180 return ['comments ' => [new Doc ($ this ->docBlock ->generate ())]];
181181 }
182182
183- if ($ this ->typed === false || $ this ->docBlockComment ) {
183+ if ($ this ->typed === false || $ this ->docBlockComment !== null ) {
184184 $ docBlockType = new VarTag ($ this ->type ->types ());
185185
186186 if ($ typeHint = $ this ->getTypeDocBlockHint ()) {
You can’t perform that action at this time.
0 commit comments