Personal dev environment setup for macOS and Linux.
# Install zsh (Linux only — macOS already has it)
sudo apt-get install -y zsh| const jwt = require('jsonwebtoken'); | |
| module.exports = { | |
| async authenticateToken(request, response, next) { | |
| const authHeader = request.headers['authorization'] | |
| const [scheme, token] = authHeader && authHeader.split(' '); | |
| if (token === null) return response.status(401).json({ error: 'No token provided' }); | |
| if (!/^Bearer$/i.test(scheme)) |