Fixing wrong property access

This commit is contained in:
Fabian Stamm 2019-03-14 17:57:40 +00:00
parent ea34da50e4
commit e800dd266a

View File

@ -12,8 +12,8 @@ export function GetClientAuthMiddleware(checksecret = true, internal = false, ch
let client_id = req.query.client_id || req.body.client_id;
let client_secret = req.query.client_secret || req.body.client_secret;
if(!client_id && !client_secret && req.query.headers.authorization) {
let header = req.query.headers.authorization;
if(!client_id && !client_secret && req.headers.authorization) {
let header = req.headers.authorization;
let [type, val] = header.split(" ");
if(val) {
let str = Buffer.from(val, "base64").toString("utf-8");