module Rails
def public_path
Rails.public_path
Rails project, otherwise it returns +nil+ if there is no project:
Returns a Pathname object of the public folder of the current
def public_path application && Pathname.new(application.paths["public"].first) end