Module: LoginRequirements
- Included in:
- JDC::App::Base, JDC::Domain::Base, JDC::Populators::Base, JDC::Route::Base, JDC::Service::Base
- Defined in:
- lib/jdc/cli/login_requirements.rb
Instance Method Summary collapse
Instance Method Details
#precondition ⇒ Object
2 3 4 5 6 7 8 9 10 11 12 13 14 |
# File 'lib/jdc/cli/login_requirements.rb', line 2 def precondition check_key check_organization_and_space #check_logged_in unless client.current_organization fail "Please select an organization with 'jdc target --organization ORGANIZATION_NAME'. (Get organization names from 'jdc orgs'.)" end unless client.current_space fail "Please select a space with 'jdc target --space SPACE_NAME'. (Get space names from 'jdc spaces'.)" end end |