Skip to content

Commit

Permalink
make code express compatible
Browse files Browse the repository at this point in the history
  • Loading branch information
AmeanAsad committed Feb 2, 2024
1 parent fa4a194 commit 9e68d74
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions container/shim/src/utils/jwt.js
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
import jwt from "jsonwebtoken";

export function findJWT(req) {
const jwtQuery = req.variables.arg_jwt;
function findJWT(req) {
const jwtQuery = req.query.jwt;

let jwtHeader = "";
const authHeader = req.variables.http_authorization;
if (authHeader) {
const authHeader = req.headers.authorization;
if (authHeader && authHeader.startsWith("Bearer ")) {
jwtHeader = authHeader.replace("Bearer ", "");
}

Expand Down

0 comments on commit 9e68d74

Please sign in to comment.