mirror of
https://github.com/steedos/steedos-platform
synced 2024-11-22 17:06:42 +00:00
vscode.steedos.com 会处理cookies。规则是cookie的value中如果有逗号,则会给value自动添加双引号 #2670
This commit is contained in:
parent
310c02812e
commit
93186ed790
@ -114,7 +114,7 @@ export async function auth(request: Request, response: Response): Promise<any> {
|
|||||||
let cookies = new Cookies(request, response);
|
let cookies = new Cookies(request, response);
|
||||||
let authToken: string =
|
let authToken: string =
|
||||||
request.headers["x-auth-token"] || (cookies.get("X-Auth-Token") || "").replace(/"/g, "");
|
request.headers["x-auth-token"] || (cookies.get("X-Auth-Token") || "").replace(/"/g, "");
|
||||||
let spaceToken = cookies.get("X-Space-Token").replace(/"/g, "");
|
let spaceToken = (cookies.get("X-Space-Token") || "").replace(/"/g, "");
|
||||||
let authorization = request.headers.authorization;
|
let authorization = request.headers.authorization;
|
||||||
let spaceId =
|
let spaceId =
|
||||||
(request.params ? request.params.spaceId : null) ||
|
(request.params ? request.params.spaceId : null) ||
|
||||||
|
Loading…
Reference in New Issue
Block a user