Sha256: 0f23f1581a8ac89680897cfbe3be7402ea7b4c8efb06f3e1441e53a8b7f430cb
Contents?: true
Size: 811 Bytes
Versions: 62
Compression:
Stored size: 811 Bytes
Contents
require "cf/cli/populators/base" require "cf/cli/populators/populator_methods" module CF module Populators class Organization < Base include PopulatorMethods def changed info[:space] = nil end private def choices organization_response = client.organizations_first_page(:depth => 0) if organization_response[:next_page] "Login successful. Too many organizations (>50) to list. Remember to set your target organization using 'target -o [ORGANIZATION]'." else organization_response[:results] end end def valid?(organization) return false unless organization.guid organization.users.include? client.current_user rescue CFoundry::APIError false end end end end
Version data entries
62 entries across 62 versions & 2 rubygems