Skip to content

Commit

Permalink
Testing
Browse files Browse the repository at this point in the history
  • Loading branch information
IT21042324 committed Apr 22, 2024
1 parent 566dd53 commit c885c41
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions middleware/requireAuth.js
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,8 @@ const requireAuth = async (req, res, next) => {
// Verify the token using the secret key
const { id } = jwt.verify(token, secret);

console.log(id);

// Retrieve user data from API using the id and role from the token
const { data } = await axios.get(`${backendUrl}/api/users/${id}`);

Expand Down

0 comments on commit c885c41

Please sign in to comment.