Quantcast
Viewing all articles
Browse latest Browse all 42

Answer by Chris for Ruby if else syntax

You need to look at look into user.image.nil? user.image.empty? and user.image.blank? depending on what you're using and apply the same to the rest of your conditional. You need to find out specifically what your looking for or the if else won't give you what you want. I would try empty first which checks if something is nil or is an empty string.


Viewing all articles
Browse latest Browse all 42

Trending Articles