Skip to content

fix(parser): cognito validationData may be null - #5250

Merged
svozza merged 1 commit into
aws-powertools:mainfrom
bdellegrazie:fix/issue-5249-parser-cognito-pre-auth-trigger
May 14, 2026
Merged

svozza merged 1 commit into
aws-powertools:mainfrom
bdellegrazie:fix/issue-5249-parser-cognito-pre-auth-trigger

Conversation

@bdellegrazie

@bdellegrazie bdellegrazie commented May 14, 2026 •

Copy link
Copy Markdown
Contributor

Summary

For the Cognito Trigger pre-authentication event, handle the possibility that the validationData may be null instead of absent.

Changes

As reported in #5249 validationData may be null instead of optional. Adjust the Zod schema to handle this as well.
I have included a test.

Issue number: closes #5249


By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.

For the Cognito Trigger pre-authentication event, handle the possiblity
that the `validationData` may be null instead of just absent.

Fixes: aws-powertools#5249
@svozza svozza changed the title fix(parser): cognito validationData may be null May 14, 2026
@svozza
svozza merged commit b3c1293 into aws-powertools:main May 14, 2026
36 checks passed
@bdellegrazie
bdellegrazie deleted the fix/issue-5249-parser-cognito-pre-auth-trigger branch May 14, 2026 08:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

size/S PR between 10-29 LOC

2 participants