Laravel-Cors给传递给Barryvdh \ Cors \ HandleCors :: addHeaders()的错误参数2

时间:2019-04-02 18:14:02

标签: cors laravel-5.8

我只是将laravel-cors与vueJs一起使用。它工作正常,但有时会出现类似以下的错误:

Argument 2 passed to Barryvdh\Cors\HandleCors::addHeaders() must be an instance of Symfony\Component\HttpFoundation\Response, array given, called in /opt/lampp/htdocs/inventory/vendor/barryvdh/laravel-cors/src/HandleCors.php on line 60 {"exception":"[object] (Symfony\\Component\\Debug\\Exception\\FatalThrowableError(code: 0):

0 个答案:

没有答案