Exception: ActiveRecordDoctor::Error::UnrecognizedGlobalSetting

Inherits:
ActiveRecordDoctor::Error show all
Defined in:
lib/active_record_doctor/errors.rb

Instance Attribute Summary

Attributes inherited from ActiveRecordDoctor::Error

#config_path

Instance Method Summary collapse

Methods inherited from ActiveRecordDoctor::Error

[], #user_message

Constructor Details

#initialize(name, recognized_settings) ⇒ UnrecognizedGlobalSetting

Returns a new instance of UnrecognizedGlobalSetting.



193
194
195
196
# File 'lib/active_record_doctor/errors.rb', line 193

def initialize(name, recognized_settings)
  @recognized_settings = recognized_settings
  super("Global #{name} is unrecognized")
end

Instance Method Details

#detailsObject



198
199
200
201
202
203
204
205
206
207
# File 'lib/active_record_doctor/errors.rb', line 198

def details
  <<-MESSAGE
The configuration file set an unrecognized global setting. Please ensure that
only recognized global settings are used and retry.

Currently recognized global settings are:

#{hyphenated_list(@recognized_settings)}
  MESSAGE
end