melloware opened a new pull request, #1148: URL: https://github.com/apache/myfaces/pull/1148
Fixes [MYFACES-4786](https://issues.apache.org/jira/browse/MYFACES-4786) A `void` action method yields a `null` outcome, which can still match a navigation case that uses `<from-action>` + `<if>` (no `<from-outcome>`). When that case has `<redirect/>`, `handleNavigation` calls `calculateTargetFlow()` with the null outcome, which reaches `FlowHandler.getFlow(ctx, "", null)` and fails with `NullPointerException: id is null`. A null outcome can never identify a flow, so `calculateTargetFlow()` now returns `null` early. The other flow lookups in `NavigationHandlerImpl` already guard against a null outcome (e.g. `getNavigationCommand`). Test: `NavigationHandlerImplTest` gains a case with a `from-action` + `if` + `redirect` rule and a null outcome, using the real `FlowHandlerImpl` (the mock one doesn't validate its arguments). It fails with `id is null` without the fix. 🤖 Generated with [Claude Code](https://claude.com/claude-code) -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
