Fix ambiguous & prefix in action_view_conditional_url_helper.rb#781
Fix ambiguous & prefix in action_view_conditional_url_helper.rb#781kitcommerce merged 1 commit intonextfrom
Conversation
Change `capture &block` to `capture(&block)` in both link_to_if_with_block and link_to_unless_with_block to resolve Ruby 3.4 warning: 'ambiguous `&` has been interpreted as an argument prefix'. Fixes #779
Simplicity ReviewVerdict: PASS Findings
Recommendations
Reviewed by: Simplicity Reviewer | Pipeline: SDLC review |
Rails Conventions Review{
"reviewer": "rails-conventions",
"verdict": "PASS",
"severity": null,
"summary": "Two-line syntactic fix with no Rails convention implications; change is idiomatic and correct.",
"findings": []
}AnalysisThe diff changes
The parenthetical form |
Security ReviewVerdict: PASS FindingsNo security findings. This change adds explicit parentheses to two RecommendationsNone. |
Architecture ReviewVerdict: PASS FindingsNo architectural concerns. This is a two-line parenthetical style fix ( The freedom patch itself ( RecommendationsNone. |
Rails Security ReviewVerdict: PASS FindingsNo security findings. This change converts Checked against rails-security scope:
RecommendationsNone. Clean pass. |
Database ReviewVerdict: PASS FindingsNo database-related changes detected. This PR modifies only Ruby method call syntax ( RecommendationsNone. |
Test Quality ReviewVerdict: PASS SummaryThis PR makes a purely syntactic change — replacing Findings
Recommendations
Reviewed by: test-quality wave 2 |
Frontend ReviewVerdict: PASS FindingsNone. This diff contains no JavaScript, TypeScript, Stimulus controllers, Turbo frames/streams, or any other frontend assets. The changes are limited to two Ruby syntax corrections in a server-side ActionView helper ( RecommendationsNone. No frontend action required. |
Accessibility ReviewVerdict: PASS Findings
Recommendations
Wave 3 Accessibility Reviewer — automated review via SDLC pipeline |
Performance ReviewVerdict: PASS ✅ Findings
Recommendations
|
✅ All Review Waves PassedAll reviewers returned PASS. This PR is merge-ready.
Labeled |
Summary
Fix Ruby 3.4 warning:
ambiguous&has been interpreted as an argument prefixinaction_view_conditional_url_helper.rb.Both
capture &blockcalls have been changed tocapture(&block)— a parenthetical style fix with no behavior change.Changes
link_to_if_with_block:capture &block→capture(&block)link_to_unless_with_block:capture &block→capture(&block)Verification
ruby -W core/lib/workarea/ext/freedom_patches/action_view_conditional_url_helper.rb— exits 0, no warningsClient impact
None expected. This is a style-only fix with no behavioral change.
Closes #779