Skip to content

Commit 43af763

Browse files
committed
Better header name
1 parent 2e29132 commit 43af763

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

packages/core/src/request.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -149,7 +149,7 @@ export class Request {
149149
.map(([key]) => key)
150150

151151
if (onceProps.length > 0) {
152-
headers['X-Inertia-Page-Once-Props'] = onceProps.join(',')
152+
headers['X-Inertia-Except-Once-Props'] = onceProps.join(',')
153153
}
154154

155155
return headers

tests/app/server.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1424,7 +1424,7 @@ app.post('/view-transition/form-errors', (req, res) =>
14241424
const getOncePropsData = (req, prop = 'foo') => {
14251425
const isInertiaRequest = !!req.headers['x-inertia']
14261426
const partialData = req.headers['x-inertia-partial-data']?.split(',') ?? []
1427-
const loadedOnceProps = req.headers['x-inertia-page-once-props']?.split(',') ?? []
1427+
const loadedOnceProps = req.headers['x-inertia-except-once-props']?.split(',') ?? []
14281428
const isPartialRequest = partialData.includes(prop)
14291429
const hasPropAlready = loadedOnceProps.includes(prop)
14301430
const shouldResolveProp = !isInertiaRequest || isPartialRequest || !hasPropAlready

0 commit comments

Comments
 (0)