Module: TTY::Utils
Instance Method Summary collapse
Instance Method Details
#extract_options(args) ⇒ Object
11 12 13 14 |
# File 'lib/tty/support/utils.rb', line 11 def (args) = args.last .respond_to?(:to_hash) ? .to_hash.dup : {} end |
#extract_options!(args) ⇒ Object
7 8 9 |
# File 'lib/tty/support/utils.rb', line 7 def (args) args.last.respond_to?(:to_hash) ? args.pop : {} end |