next.js
2baf4f74 - fix: Enable SearchParams to be displayed after redirect in Server Action (#62582)

Commit
1 year ago
fix: Enable SearchParams to be displayed after redirect in Server Action (#62582) ### What? Fixes https://github.com/vercel/next.js/issues/62525 Closes NEXT-2620 Since codes below do not consider searchParams, `redirect` in server action removes all searchParams passed from client side. https://github.com/vercel/next.js/commit/93e4bb823ccb6452ba591e29a3ec0b258b3a9b5c#diff-c809d50461027cdba7c092e564818b1172133d337abc5c513f829c94c8483dc6R186 So I just add conditional branch for searchParams. --- lint, prettier was applied. Also I have done tests by commands below. and it was all passed. ``` pnpm testonly --testPathPattern "integration" -t "redirect" ``` --------- Co-authored-by: Zack Tanner <zacktanner@gmail.com>
Parents
Loading