Sha256: 3b87570c7cef72a57df7089b7ca9c5ba914605fb69e686ce387f4b8c75575174

Contents?: true

Size: 792 Bytes

Versions: 36

Compression:

Stored size: 792 Bytes

Contents

class Zendesk2::Client
  class Real
    def update_user_identity(params={})
      id      = params.delete("id")
      user_id = params.delete("user_id")
      path    = "/users/#{user_id}/identities/#{id}.json"

      request(
        :method => :put,
        :path   => path,
        :body   => {
          "identity" => params
        },
      )
    end
  end
  class Mock
    def update_user_identity(params={})
      id      = params.delete("id")
      user_id = params.delete("user_id")
      path    = "/users/#{user_id}/identities/#{id}.json"

      body = self.data[:identities][id].merge!(Cistern::Hash.slice(params, "verified"))
      response(
        :method => :put,
        :path   => path,
        :body   => {
          "identity" => body
        },
      )
    end
  end
end

Version data entries

36 entries across 36 versions & 1 rubygems

Version Path
zendesk2-0.4.1 lib/zendesk2/client/requests/update_user_identity.rb
zendesk2-0.4.0 lib/zendesk2/client/requests/update_user_identity.rb
zendesk2-0.3.2 lib/zendesk2/client/requests/update_user_identity.rb
zendesk2-0.3.1 lib/zendesk2/client/requests/update_user_identity.rb
zendesk2-0.3.0 lib/zendesk2/client/requests/update_user_identity.rb
zendesk2-0.2.7 lib/zendesk2/client/requests/update_user_identity.rb
zendesk2-0.2.6 lib/zendesk2/client/requests/update_user_identity.rb
zendesk2-0.2.5 lib/zendesk2/client/requests/update_user_identity.rb
zendesk2-0.2.4 lib/zendesk2/client/requests/update_user_identity.rb
zendesk2-0.2.3 lib/zendesk2/client/requests/update_user_identity.rb
zendesk2-0.2.2 lib/zendesk2/client/requests/update_user_identity.rb
zendesk2-0.2.1 lib/zendesk2/client/requests/update_user_identity.rb
zendesk2-0.2.0 lib/zendesk2/client/requests/update_user_identity.rb
zendesk2-0.1.3 lib/zendesk2/client/requests/update_user_identity.rb
zendesk2-0.1.2 lib/zendesk2/client/requests/update_user_identity.rb
zendesk2-0.1.1 lib/zendesk2/client/requests/update_user_identity.rb