Skip to content

types: reply.getSerializationFunction can return undefined#5384

Merged
mcollina merged 1 commit intofastify:mainfrom
remidewitte:fix-type-getSerializationFunction
Apr 29, 2024
Merged

types: reply.getSerializationFunction can return undefined#5384
mcollina merged 1 commit intofastify:mainfrom
remidewitte:fix-type-getSerializationFunction

Conversation

@remidewitte
Copy link
Copy Markdown
Contributor

@remidewitte remidewitte commented Apr 3, 2024

When the schema have not yet been compiled with reply.compileSerializationSchema, reply.getSerializationFunction can return undefined.

See :

serialize = this[kRouteContext][kReplyCacheSerializeFns]?.get(schemaOrStatus)

Checklist

@remidewitte remidewitte changed the title reply.getSerializationFunction can return undefined types: reply.getSerializationFunction can return undefined Apr 3, 2024
Copy link
Copy Markdown
Member

@mcollina mcollina left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm

@mcollina mcollina merged commit 20e3e35 into fastify:main Apr 29, 2024
@github-actions
Copy link
Copy Markdown

This pull request has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Apr 30, 2025
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants