CORS policy blocking redirct due to origin 'null'


I’m trying to implement logout functionality but getting the following error.

Access to fetch at ‘’ (redirected from ‘’) from origin ‘null’ has been blocked by CORS policy: No ‘Access-Control-Allow-Origin’ header is present on the requested resource. If an opaque response serves your needs, set the request’s mode to ‘no-cors’ to fetch the resource with CORS disabled.