Skip to content
Browse files

Fixing idiom for retired_switch.

I poked around your code at random, and noticed this little thing.
  • Loading branch information...
1 parent 71f737a commit 7e7c37091cba16142730edd0d18edb30d5b565e5 @steveklabnik committed Apr 19, 2012
Showing with 1 addition and 4 deletions.
  1. +1 −4 app/models/product.rb
View
5 app/models/product.rb
@@ -21,10 +21,7 @@ def category_list
end
def retired_switch
- case retired
- when true then false
- when false then true
- end
+ !retired
end
def badge_html

0 comments on commit 7e7c370

Please sign in to comment.
Something went wrong with that request. Please try again.