Sha256: cb8474fa64a51fb5f19d080fc93d18900ae711d4ccf9897b610b30388b90e69a
Contents?: true
Size: 514 Bytes
Versions: 6
Compression:
Stored size: 514 Bytes
Contents
# frozen_string_literal: true module ActionKitRest class User < Base def base_path 'user' end def get(id) user = super(id) # Perform a second request to retrieve user's phones data if any available # (user.phones attribute includes the path for associated phones, not the data itself) if user.id.present? && user.phones.any? phones_list = client.phone.list(user: user.id) user.obj.phones = phones_list.obj.to_a end user end end end
Version data entries
6 entries across 6 versions & 1 rubygems