summaryrefslogtreecommitdiff
path: root/lib/chef_zero/endpoints/user_association_requests_endpoint.rb
diff options
context:
space:
mode:
Diffstat (limited to 'lib/chef_zero/endpoints/user_association_requests_endpoint.rb')
-rw-r--r--lib/chef_zero/endpoints/user_association_requests_endpoint.rb8
1 files changed, 4 insertions, 4 deletions
diff --git a/lib/chef_zero/endpoints/user_association_requests_endpoint.rb b/lib/chef_zero/endpoints/user_association_requests_endpoint.rb
index d8dc6eb..c8db13b 100644
--- a/lib/chef_zero/endpoints/user_association_requests_endpoint.rb
+++ b/lib/chef_zero/endpoints/user_association_requests_endpoint.rb
@@ -1,5 +1,5 @@
-require 'ffi_yajl'
-require 'chef_zero/rest_base'
+require "ffi_yajl"
+require "chef_zero/rest_base"
module ChefZero
module Endpoints
@@ -8,8 +8,8 @@ module ChefZero
def get(request)
get_data(request, request.rest_path[0..-2])
username = request.rest_path[1]
- result = list_data(request, [ 'organizations' ]).select do |org|
- exists_data?(request, [ 'organizations', org, 'association_requests', username ])
+ result = list_data(request, [ "organizations" ]).select do |org|
+ exists_data?(request, [ "organizations", org, "association_requests", username ])
end
result = result.map { |org| { "id" => "#{username}-#{org}", "orgname" => org } }
json_response(200, result)