Class: DlRacktables::Output
- Inherits:
-
Object
- Object
- DlRacktables::Output
- Defined in:
- lib/dl_racktables/output.rb
Class Method Summary collapse
Class Method Details
.error(msg) ⇒ Object
10 11 12 13 14 15 |
# File 'lib/dl_racktables/output.rb', line 10 def self.error(msg) puts JSON.dump({ 'status' => 'error', 'msg' => msg, }) end |
.success(opts) ⇒ Object
5 6 7 8 9 |
# File 'lib/dl_racktables/output.rb', line 5 def self.success(opts) puts JSON.dump(opts.merge({ 'status' => 'success', })) end |