Class: Cl::RequiredOpts

Inherits:
OptionError
  • Object
show all
Defined in:
lib/cl/errors.rb

Instance Method Summary collapse

Constructor Details

#initialize(opts) ⇒ RequiredOpts

Returns a new instance of RequiredOpts.


26
27
28
29
# File 'lib/cl/errors.rb', line 26

def initialize(opts)
  msg = opts.size == 1 ? :required_opt : :required_opts
  super(msg, opts.join(', '))
end