You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
throw new \Tinywan\ExceptionHandler\Exception\TooManyRequestsHttpException(trans('请求频繁'), ['errorCode' => 4000]);
会报下面的错误,其他请求正常,只有这个TooManyRequestsHttpException会报。
Access to XMLHttpRequest at 'http://192.168.2.66:8789/user' from origin 'http://localhost' has been blocked by CORS policy: The 'Access-Control-Allow-Origin' header contains multiple values '*, http://localhost', but only one is allowed.
throw new \Tinywan\ExceptionHandler\Exception\TooManyRequestsHttpException(trans('请求频繁'), ['errorCode' => 4000]);
会报下面的错误,其他请求正常,只有这个TooManyRequestsHttpException会报。
Access to XMLHttpRequest at 'http://192.168.2.66:8789/user' from origin 'http://localhost' has been blocked by CORS policy: The 'Access-Control-Allow-Origin' header contains multiple values '*, http://localhost', but only one is allowed.
我在使用Axios进行跨域请求的时候,无法识别到这个状态,直接返回ERR_NETWORK,在TooManyRequestsHttpException里面设置的请求头似乎影响了这个问题,去掉下面这个 $header请求头就正常了。前提是我有做全局的跨域处理。我不是很懂,你可以确认一下这个情况。
The text was updated successfully, but these errors were encountered: