Class: Actions::Pulp::Consumer::ContentPresenter
- Inherits:
-
Helpers::Presenter::Base
- Object
- Helpers::Presenter::Base
- Actions::Pulp::Consumer::ContentPresenter
- Defined in:
- app/lib/actions/pulp/consumer.rb
Instance Attribute Summary
Attributes inherited from Helpers::Presenter::Base
Instance Method Summary collapse
Methods inherited from Helpers::Presenter::Base
Constructor Details
This class inherits a constructor from Actions::Helpers::Presenter::Base
Instance Method Details
#humanized_output ⇒ Object
5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 |
# File 'app/lib/actions/pulp/consumer.rb', line 5 def humanized_output if task_result_packages ret = [] if task_result_packages.is_a?(String) ret << task_result_packages elsif task_result_packages.any? ret.concat(task_result_packages.map { |package| package[:qname] }) else ret << humanized_no_package end if humanized_errors ret.concat(humanized_errors) end return ret.join("\n") else humanized_errors #show any errors if no packages were updated end end |