Skip to content

Commit 6b00d09

Browse files
authored
Merge 271eaff into ce0589a
2 parents ce0589a + 271eaff commit 6b00d09

File tree

3 files changed

+18
-10
lines changed

3 files changed

+18
-10
lines changed

package-lock.json

+9-9
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

packages/runtime/package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
"manifest.yml"
1010
],
1111
"dependencies": {
12-
"@netlify/functions": "^1.0.0",
12+
"@netlify/functions": "^1.1.0",
1313
"@netlify/ipx": "^1.2.0",
1414
"@vercel/node-bridge": "^2.1.0",
1515
"chalk": "^4.1.2",

packages/runtime/src/templates/getHandler.ts

+8
Original file line numberDiff line numberDiff line change
@@ -101,6 +101,14 @@ const makeHandler = (conf: NextConfig, app, pageRoot, staticManifest: Array<[str
101101
const query = new URLSearchParams(event.queryStringParameters).toString()
102102
event.path = query ? `${event.path}?${query}` : event.path
103103

104+
const graphToken = event.netlifyGraphToken
105+
if (graphToken && requestMode !== 'ssr') {
106+
// Prefix with underscore to help us determine the origin of the token
107+
// allows us to write better error messages
108+
// eslint-disable-next-line no-underscore-dangle
109+
process.env._NETLIFY_GRAPH_TOKEN = graphToken
110+
}
111+
104112
const { headers, ...result } = await getBridge(event).launcher(event, context)
105113

106114
// Convert all headers to multiValueHeaders

0 commit comments

Comments
 (0)