payloadcms / payloadcms/payload
`point` field is not returned on update by ID
Nobody has claimed this yet.
- Dominant language
- TypeScript
- Stars
- 44.8k
- Forks
- 4.2k
- Avg merge
- 2d 21h
- Merged PRs (30d)
- 53
Description
Describe the Bug
In a collection that declares a "point" field, when updating a single item by id, that field is neither available to afterRead hook nor included in the result
claude suggests this change in packages/drizzle/src/upsertRow/index.ts:153
if (findManyArgs.extras) {
for (const [name, extra] of Object.entries(findManyArgs.extras)) {
selectedFields[name] = extra
}
}
Link to the code that reproduces this issue
https://github.com/rafalkrupinski/payload-field-point
Reproduction Steps
- create an item in the item collection
- update any field in the created item
either use curl or the browser dev console to see the response body
Which area(s) are affected?
db: postgres
Environment Info
Binaries:
Node: 26.4.0
npm: 12.0.1
Yarn: N/A
pnpm: 11.3.0
Relevant Packages:
payload: 3.86.0
next: 16.2.6
@payloadcms/db-postgres: 3.86.0
@payloadcms/drizzle: 3.86.0
@payloadcms/graphql: 3.86.0
@payloadcms/next/utilities: 3.86.0
@payloadcms/richtext-lexical: 3.86.0
@payloadcms/translations: 3.86.0
@payloadcms/ui/shared: 3.86.0
react: 19.2.6
react-dom: 19.2.6
Operating System:
...
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start in packages/drizzle/src/upsertRow/index.ts around line 153 and inspect how extras are selected during update-by-ID operations. Run the reproduction linked in the issue, update an existing item, and check both the afterRead hook and response body. Done means the point field is available to the hook and included in the update result.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- postgresql, typescript
- Domain
- database
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 68/100