class method
self.create_command
Ruby on Rails 8.1.2
Since v5.2.8.1 PrivateSignature
self.create_command(meth)
Allow the command method to be called perform.
Parameters
-
methreq
Source
# File railties/lib/rails/command/base.rb, line 144
def create_command(meth)
if meth == "perform"
alias_method command_name, meth
else
# Prevent exception about command without usage.
# Some commands define their documentation differently.
@usage ||= meth
@desc ||= ""
super
end
end
Defined in railties/lib/rails/command/base.rb line 144
· View on GitHub
· Improve this page
· Find usages on GitHub
Defined in Rails::Command::Base