Exception: BranchIOCLI::Helper::CommandError
- Inherits:
-
RuntimeError
- Object
- RuntimeError
- BranchIOCLI::Helper::CommandError
- Defined in:
- lib/branch_io_cli/helper/methods.rb
Instance Attribute Summary collapse
-
#status ⇒ Object
readonly
Returns the value of attribute status.
Instance Method Summary collapse
-
#initialize(args) ⇒ CommandError
constructor
A new instance of CommandError.
- #message ⇒ Object
Constructor Details
#initialize(args) ⇒ CommandError
Returns a new instance of CommandError.
5 6 7 8 9 |
# File 'lib/branch_io_cli/helper/methods.rb', line 5 def initialize(args) @args = args[0] @status = args[1] super end |
Instance Attribute Details
#status ⇒ Object (readonly)
Returns the value of attribute status.
4 5 6 |
# File 'lib/branch_io_cli/helper/methods.rb', line 4 def status @status end |
Instance Method Details
#message ⇒ Object
11 12 13 14 15 16 17 18 |
# File 'lib/branch_io_cli/helper/methods.rb', line 11 def if @args.count == 1 return @args.first.shelljoin if @args.first.kind_of?(Array) return @args.first.to_s else return @args.shelljoin end end |