Exception: Nvar::EnvironmentVariableNotPresentError
- Defined in:
- lib/nvar.rb
Overview
Error that is raised when an environment variable is blank or unset when it is required
Instance Attribute Summary collapse
-
#vars ⇒ Object
readonly
Returns the value of attribute vars.
Instance Method Summary collapse
-
#initialize(*vars) ⇒ EnvironmentVariableNotPresentError
constructor
A new instance of EnvironmentVariableNotPresentError.
- #message ⇒ Object
Constructor Details
#initialize(*vars) ⇒ EnvironmentVariableNotPresentError
Returns a new instance of EnvironmentVariableNotPresentError.
30 31 32 33 |
# File 'lib/nvar.rb', line 30 def initialize(*vars) @vars = vars super() end |
Instance Attribute Details
#vars ⇒ Object (readonly)
Returns the value of attribute vars.
28 29 30 |
# File 'lib/nvar.rb', line 28 def vars @vars end |
Instance Method Details
#message ⇒ Object
35 36 37 |
# File 'lib/nvar.rb', line 35 def "The following variables are unset or blank: #{vars.map(&:name).join(', ')}" end |