Exception: SmartParams::NoMatchingNamespaceException

Inherits:
StandardError
  • Object
show all
Defined in:
lib/smart_params/no_matching_namespace_exception.rb

Instance Method Summary collapse

Constructor Details

#initialize(namespace:, available:) ⇒ NoMatchingNamespaceException

Returns a new instance of NoMatchingNamespaceException.



5
6
7
8
9
# File 'lib/smart_params/no_matching_namespace_exception.rb', line 5

def initialize(namespace:, available:)
  @namespace = namespace
  @available = available
  super(message)
end

Instance Method Details

#messageObject



11
12
13
# File 'lib/smart_params/no_matching_namespace_exception.rb', line 11

def message
  "#{@namespace} does not exist, only #{@available.inspect}"
end