Exception: ActionController::MethodNotAllowed

Inherits:
ActionControllerError show all
Defined in:
actionpack/lib/action_controller/metal/exceptions.rb

Overview

:nodoc:

Direct Known Subclasses

NotImplemented

Instance Attribute Summary (collapse)

Instance Method Summary (collapse)

Constructor Details

- (MethodNotAllowed) initialize(*allowed_methods)



19
20
21
# File 'actionpack/lib/action_controller/metal/exceptions.rb', line 19

def initialize(*allowed_methods)
  super("Only #{allowed_methods.to_sentence(:locale => :en)} requests are allowed.")
end

Instance Attribute Details

- (Object) allowed_methods (readonly)

Returns the value of attribute allowed_methods



17
18
19
# File 'actionpack/lib/action_controller/metal/exceptions.rb', line 17

def allowed_methods
  @allowed_methods
end