Class: String
Instance Method Summary collapse
Instance Method Details
#encrypt ⇒ Object
6 7 8 |
# File 'lib/mori/string.rb', line 6 def encrypt Password.create(self, :cost => cost) end |
#normalize ⇒ Object
9 10 11 |
# File 'lib/mori/string.rb', line 9 def normalize self.remove_whitespace.downcase end |
#remove_whitespace ⇒ Object
12 13 14 |
# File 'lib/mori/string.rb', line 12 def remove_whitespace self.gsub(/\s+/, '') end |