module ActiveSupport::Inflector

def upcase_first(string)

upcase_first('') # => ""
upcase_first('w') # => "W"
upcase_first('what a Lovely Day') # => "What a Lovely Day"

Converts just the first character to uppercase.
def upcase_first(string)
  string.length > 0 ? string[0].upcase.concat(string[1..-1]) : ""
end