mirror of
https://github.com/terribleplan/next.js.git
synced 2024-01-19 02:48:18 +00:00
Fixed how credentials opt is passed to HttpLink (#3269)
Prior to react-apollo 2.0 createNetworkInterface accepted the credentials option in {opt: {credentials: 'policy'}}. HttpLink accepts it as {credentials: 'policy'}.
This commit is contained in:
parent
80a1603189
commit
d72d3c09ef
|
@ -16,9 +16,7 @@ function create (initialState) {
|
|||
ssrMode: !process.browser, // Disables forceFetch on the server (so queries are only run once)
|
||||
link: new HttpLink({
|
||||
uri: 'https://api.graph.cool/simple/v1/cixmkt2ul01q00122mksg82pn', // Server URL (must be absolute)
|
||||
opts: {
|
||||
credentials: 'same-origin' // Additional fetch() options like `credentials` or `headers`
|
||||
}
|
||||
credentials: 'same-origin' // Additional fetch() options like `credentials` or `headers`
|
||||
}),
|
||||
cache: new InMemoryCache().restore(initialState || {}),
|
||||
})
|
||||
|
|
Loading…
Reference in a new issue