Favor the ternary operator. 🚓
This commit is contained in:
parent
7cb9c7d8ea
commit
0dba294f99
1 changed files with 1 additions and 1 deletions
|
@ -56,7 +56,7 @@ module MilestonesHelper
|
||||||
|
|
||||||
def milestone_remaining_days(milestone, withContentTag = true)
|
def milestone_remaining_days(milestone, withContentTag = true)
|
||||||
if milestone.expired?
|
if milestone.expired?
|
||||||
if withContentTag then content_tag(:strong, 'expired') else 'expired' end
|
withContentTag ? content_tag(:strong, 'expired') : 'expired'
|
||||||
elsif milestone.due_date
|
elsif milestone.due_date
|
||||||
days = milestone.remaining_days
|
days = milestone.remaining_days
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue