Method deprecated or moved
This method is deprecated or moved on the latest stable version.
The last existing version (v2.3.8) is shown here.
raise_class_collision(class_name)
private
Raise a usage error with an informative WordNet suggestion. Thanks to
Florian Gross (flgr).
Show source
def raise_class_collision(class_name)
message = " The name '\#{class_name}' is either already used in your application or reserved by Ruby on Rails.\n Please choose an alternative and run this generator again.\n"
if suggest = find_synonyms(class_name)
if suggest.any?
message << "\n Suggestions: \n\n"
message << suggest.join("\n")
end
end
raise UsageError, message
end