payload-api 0.2.3 → 0.2.4

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 7622a6cdd2bb9272244defec0d7270ac8ea332ac300c7b897797ec9b9311e4f6
4
- data.tar.gz: 2e640cddf0eb931313b4f4cdaa080a2a8e24471cc7330ed8ef6cc44f1c465f55
3
+ metadata.gz: bbb1f9ed364eb3e8d721aa2e52e3998097e764c5efdb650b7c1ab840b792197d
4
+ data.tar.gz: 17e0e956231c7ae5ccfb0c63ca1a50061d4ed1812b7c8871c3d54f38e7254a05
5
5
  SHA512:
6
- metadata.gz: c77e7856968f9efa3cadd8c6625b401a2266f9725407c91a04fbc4b477a768a13d7a6e967c1175d53b627481ff47f2fb24a517d8d23e4276928b23e9259a9fde
7
- data.tar.gz: e4502563befa374e315924adc109c7e72bfdd8a29ce9d84c82c2ead3b55d619c9c89df54317644760d78a5b1bd68d1b6142b9faf27ffd9bf2e013e29f6e79841
6
+ metadata.gz: 32dc9421316afd86f9df392613d2f6c4b5ef793c0a82e5256718bf3740408ec3b055f3916d8e9a5c06d792eb5cf589338452dec6b46ad5bf0e14ab15ce8ac81b
7
+ data.tar.gz: cd79ebdffa7156488217896c5b6ae37379f9efbe9781cfcdfcd6690ae9acd21eb70c4debabd48bf0e99c45a704303df5702717c510dcfe2c6ffd672efabeed55
data/README.md CHANGED
@@ -7,7 +7,7 @@ A RubyGem for integrating [Payload](https://payload.co).
7
7
  To install using [Bundler](https://bundler.io):
8
8
 
9
9
  ```ruby
10
- gem 'payload-api', '~> 0.2.3'
10
+ gem 'payload-api', '~> 0.2.4'
11
11
  ```
12
12
 
13
13
  To install using gem:
@@ -125,7 +125,14 @@ module Payload
125
125
 
126
126
  if response.code == '200'
127
127
  if data['object'] == 'list'
128
- return data['values'].map {|obj| Payload::get_cls(obj).new(obj) }
128
+ return data['values'].map do |obj|
129
+ cls = Payload::get_cls(obj)
130
+ if cls.nil?
131
+ obj
132
+ else
133
+ cls.new(obj)
134
+ end
135
+ end
129
136
  else
130
137
  return Payload::get_cls(data).new(data)
131
138
  end
@@ -1,3 +1,3 @@
1
1
  module Payload
2
- VERSION = '0.2.3'
2
+ VERSION = '0.2.4'
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: payload-api
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.3
4
+ version: 0.2.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - Payload
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2023-02-20 00:00:00.000000000 Z
11
+ date: 2023-03-27 00:00:00.000000000 Z
12
12
  dependencies: []
13
13
  description: A simple library to interface with the Payload API. See https://docs.payload.co
14
14
  for details.