ugh
This commit is contained in:
@@ -11,9 +11,13 @@ export async function GET(req: NextRequest) {
|
||||
// If not in headers, check cookies
|
||||
if (!token) {
|
||||
token = req.cookies.get('Authorization')?.value;
|
||||
console.log('Auth check: Token from cookies');
|
||||
console.log('Auth check: Token from cookies:', token ? `${token.substring(0, 10)}...` : 'none');
|
||||
|
||||
// Debug: List all cookies
|
||||
const cookiesList = req.cookies.getAll();
|
||||
console.log('Auth check: All cookies:', JSON.stringify(cookiesList.map(c => c.name)));
|
||||
} else {
|
||||
console.log('Auth check: Token from headers');
|
||||
console.log('Auth check: Token from headers:', token.substring(0, 10) + '...');
|
||||
}
|
||||
|
||||
if (!token) {
|
||||
|
||||
Reference in New Issue
Block a user