Skip to content

Remove multiline ternary operator#8034

Merged
javierjulio merged 1 commit into
activeadmin:masterfrom
tagliala:chore/remove-multiline-ternary-operator
Oct 7, 2023
Merged

Remove multiline ternary operator#8034
javierjulio merged 1 commit into
activeadmin:masterfrom
tagliala:chore/remove-multiline-ternary-operator

Conversation

@tagliala

Copy link
Copy Markdown
Contributor

Replace multiline ternary operator with a standard if...else for readability and better code coverage

master

Fake Coverage 100%

image

this branch

Real Coverage 96.43%

image

@codecov

codecov Bot commented Jul 28, 2023

Copy link
Copy Markdown

Codecov Report

All modified lines are covered by tests ✅

Comparison is base (e85fc76) 99.04% compared to head (3a62c3d) 99.04%.

Additional details and impacted files
@@           Coverage Diff           @@
##           master    #8034   +/-   ##
=======================================
  Coverage   99.04%   99.04%           
=======================================
  Files         185      185           
  Lines        4730     4733    +3     
=======================================
+ Hits         4685     4688    +3     
  Misses         45       45           
Files Coverage Δ
lib/active_admin/order_clause.rb 100.00% <100.00%> (ø)
...active_admin/views/components/active_admin_form.rb 100.00% <100.00%> (ø)
lib/active_admin/views/pages/index.rb 100.00% <100.00%> (ø)

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@javierjulio javierjulio force-pushed the chore/remove-multiline-ternary-operator branch from 084bc25 to 7238c67 Compare August 12, 2023 17:11
@tagliala tagliala force-pushed the chore/remove-multiline-ternary-operator branch from 7238c67 to 9535a20 Compare October 6, 2023 16:03
Comment thread lib/active_admin/order_clause.rb
Replace multiline ternary operator with a standard `if...else` for
readability and better code coverage
@tagliala tagliala force-pushed the chore/remove-multiline-ternary-operator branch from 9535a20 to 3a62c3d Compare October 7, 2023 08:34
@tagliala tagliala requested a review from javierjulio October 7, 2023 08:44

@javierjulio javierjulio left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Thanks!

@javierjulio javierjulio merged commit cf8980f into activeadmin:master Oct 7, 2023
@tagliala tagliala deleted the chore/remove-multiline-ternary-operator branch October 7, 2023 16:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants