CONST = 2 unless defined? CONST
See here for more about awesome defined? operator.
P.S. And in the future I guess you’ll want var ||= 1 instead of var = var||1.
CONST = 2 unless defined? CONST
See here for more about awesome defined? operator.
P.S. And in the future I guess you’ll want var ||= 1 instead of var = var||1.