Larastan: Call to an undefined method Illuminate\Contracts\Routing\ResponseFactory|Illuminate\Http\Response::json()

Created on 7 Sep 2018  路  3Comments  路  Source: nunomaduro/larastan

  • Larastan Version: 0.2.9
  • --level used: max

Description:

This at least on Laravel 5.7.1. False positive I assume.

Laravel code where the issue was found:

return response()->json(['message' => 'foobar']);

false positive

Most helpful comment

This improved usage of response() significantly for me, but I then ran into a problem with the phpdoc of Lumen's ResponseFactory::json() being incorrect. :)
I have submitted https://github.com/laravel/lumen-framework/pull/811

All 3 comments

@lasselehtinen This issue got addressed on the version v0.2.11. Can you test it?

This improved usage of response() significantly for me, but I then ran into a problem with the phpdoc of Lumen's ResponseFactory::json() being incorrect. :)
I have submitted https://github.com/laravel/lumen-framework/pull/811

Was this page helpful?
0 / 5 - 0 ratings

Related issues

danielcosta picture danielcosta  路  4Comments

AJenbo picture AJenbo  路  4Comments

szepeviktor picture szepeviktor  路  4Comments

mariomka picture mariomka  路  4Comments

iNviNho picture iNviNho  路  3Comments