if num=~ /\d+/
buy_num=num.to_i
else
buy_num=1
end
1 down vote accept |
You forgot to include the class you were testing against:
|