Skip to content

Commit

Permalink
cleanup style
Browse files Browse the repository at this point in the history
  • Loading branch information
grokify committed Feb 14, 2016
1 parent ddad5f1 commit 504a944
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions lib/ringcentral_sdk/rest/client.rb
Original file line number Diff line number Diff line change
Expand Up @@ -168,15 +168,15 @@ def get_api_key()
end

def send_request(request_sdk = {})
if request_sdk.is_a?(Hash)
if request_sdk.is_a? Hash
request_sdk = RingCentralSdk::REST::Request::Simple.new(request_sdk)
elsif !request_sdk.is_a?(RingCentralSdk::REST::Request::Base)
elsif !request_sdk.is_a? RingCentralSdk::REST::Request::Base
fail 'Request is not a RingCentralSdk::REST::Request::Base'
end

res = nil

method = request_sdk.method.downcase

case method
when 'delete'
res = @http.delete { |req| req = inflate_request(req, request_sdk) }
Expand Down

0 comments on commit 504a944

Please sign in to comment.