mirror of
https://github.com/jupyterhub/jupyterhub.git
synced 2025-10-11 03:52:59 +00:00
fix xsrfToken in react
caught now that we have browser tests
This commit is contained in:
@@ -8,7 +8,7 @@ export const jhapiRequest = (endpoint, method, data) => {
|
||||
if (xsrfToken) {
|
||||
// add xsrf token to url parameter
|
||||
var sep = endpoint.indexOf("?") === -1 ? "?" : "&";
|
||||
suffix = sep + "_xsrf=" + xsrf_token;
|
||||
suffix = sep + "_xsrf=" + xsrfToken;
|
||||
}
|
||||
return fetch(api_url + endpoint + suffix, {
|
||||
method: method,
|
||||
|
Reference in New Issue
Block a user