We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 85430f9 commit 4668d24Copy full SHA for 4668d24
1 file changed
src/app.js
@@ -22,19 +22,18 @@ export function createApp(req) {
22
}
23
24
if (__SERVER__ && req) {
25
- const token = req.header('authorization') || (req.cookies && req.cookies['feathers-jwt']);
26
const app = configureApp(
27
rest(host('/api')).axios(
28
axios.create({
29
headers: {
30
Cookie: req.get('cookie'),
31
- Authorization: token
+ Authorization: req.header('authorization')
32
33
})
34
)
35
);
36
37
- app.set('accessToken', token);
+ app.set('accessToken', req.cookies && req.cookies['feathers-jwt']);
38
39
return app;
40
0 commit comments