module Rails::Generators::ResourceHelpers

def initialize(*args) #:nodoc:

:nodoc:

Set controller variables on initialization.
def initialize(*args) #:nodoc:
  super
  if name == name.pluralize && name.singularize != name.pluralize && !options[:force_plural]
    unless ResourceHelpers.skip_warn
      say "Plural version of the model detected, using singularized version. Override with --force-plural."
      ResourceHelpers.skip_warn = true
    end
    name.replace name.singularize
    assign_names!(name)
  end
  @controller_name = name.pluralize
end