mirror of
https://github.com/terribleplan/next.js.git
synced 2024-01-19 02:48:18 +00:00
Fixed error with the cookie parser in with-apollo-auth (#4445)
Fixes #4442
This commit is contained in:
parent
54e152b11b
commit
2ef80a354c
|
@ -8,9 +8,7 @@ import initApollo from './initApollo'
|
||||||
|
|
||||||
function parseCookies(req, options = {}) {
|
function parseCookies(req, options = {}) {
|
||||||
return cookie.parse(
|
return cookie.parse(
|
||||||
req && req.headers.cookie
|
req ? req.headers.cookie || '' : document.cookie,
|
||||||
? req.headers.cookie
|
|
||||||
: document.cookie,
|
|
||||||
options
|
options
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue