33 Commits

Author SHA1 Message Date
Brian Krausz
f8d5687040 Fixes as requested 2015-03-05 00:07:13 -08:00
Brian Krausz
a47a754795 Support arrays & add more nested tests 2015-03-03 14:25:10 -08:00
Brian Krausz
03abd88f0c Fix updating for nested hashes 2015-03-02 18:29:59 -08:00
Brian Krausz
4d611c62f7 Support persisted use of Stripe-Account header everywhere
Including implicit use in /v1/accounts/ endpoints
2015-02-09 23:38:34 -08:00
Akshay
b9db97c6b9 Using backslash instead of string concatenation for separating multi-line messages 2015-01-24 23:17:46 +05:30
Weston Platter
30b0e4156a formatting. remove () from methods that don't have arguments 2014-11-02 20:28:43 -07:00
Tim Craft
0fc6ee5e5b Return self from Stripe::StripeObject#refresh_from 2014-08-22 19:43:13 +01:00
Amber Feng
8bb6acfca9 Merge pull request #122 from mcolyer/fix-psych-deserialization
Check for `@values` in StripeObject#method_not_found.

This is necessary because we check for `@values` in `respond_to_missing?` now, but this isn't necessarily always set. For example, in deserializing from YAML, Psych creates the object using `allocate` and not `new`, which ends up skipping any initializing of instance variables. See #122 for more details.
2014-07-08 21:52:05 -07:00
Matt Colyer
974f5ce425 Check for @values in StripeObject#method_not_found
If a StripeObject is being deserialized by psych, @values.has_key? is
called before @values is initialized which prevents proper
deserialization from occurring. Checking for existence first resolves
the issue.
2014-02-24 14:16:21 -08:00
Vladimir Andrijevik
310c69e90d In StripeObject#to_hash, call #to_hash on values which respond to it 2014-02-12 20:19:30 +01:00
Andrew Thorp
0fdd830975 fixed marshaling forrealz 2014-02-03 21:29:32 -06:00
Andrew Thorp
c46d285b47 fix lurky marshaling 2014-02-03 21:29:32 -06:00
Andrew Thorp
f74edde14c remove nilcheck of @values 2014-02-03 21:29:32 -06:00
Andrew Thorp
7ec8a12dff use _dump and self._load instead of marshal_* 2014-02-03 21:29:32 -06:00
Andrew Thorp
02b40e6637 fix tests 2014-02-03 21:29:32 -06:00
Andrew Thorp
c880d6a277 fixed marshaling of stripe objects, fixes #90 2014-02-03 21:29:32 -06:00
Andrew Thorp
7275b9b951 whoops, respond_to? cannot be protected 2014-02-03 21:29:32 -06:00
Andrew Thorp
8b5f7d038c whoops, respond_to? cannot be protected 2014-01-24 23:37:35 -08:00
Andrew Thorp
9ead81b352 replace multi_json with json, fixes #101 2014-01-24 23:27:25 -08:00
Andrew Thorp
8b3a00c587 cleaning up a pull request from @thomasbrus 2014-01-24 21:27:45 -08:00
Thomas Brus
6a7f705be3 Fall back to #respond_to? if ruby version is lower than 1.9.2 2014-01-24 21:27:45 -08:00
Thomas Brus
a4b12fac62 Override #respond_to_missing? instead 2014-01-24 21:27:45 -08:00
Thomas Brus
dc10c1b344 Implemented #respond_to? 2014-01-24 21:27:45 -08:00
kiran-b
57656f6e89 update now accounts for metadata={'key' => 'val'} syntax 2013-10-08 13:54:39 -07:00
Andrew Metcalf
d291020a43 clean up syntax 2013-08-06 15:47:33 -07:00
Andrew Metcalf
7d2ca0dbee better error messaging 2013-08-06 15:26:22 -07:00
Andrew Metcalf
88ead09193 support unsetting parameters by passing nil and updating 2013-08-06 11:37:35 -07:00
Tim Craft
6b43da28e3 Always call to_sym instead of type checking in Stripe::StripeObject#[] method 2013-03-14 14:06:09 +00:00
Ross Boucher
b2aafa854e Add id to the list of permanent attributes 2013-02-21 11:54:16 -08:00
Ross Boucher
5ffde047d3 Add the ability to send options with retrieve requests. 2013-02-01 12:12:03 -08:00
Greg Brockman
22907c7046 Fixup whitespace 2012-06-19 23:15:08 -07:00
Greg Brockman
6031cbf7b1 Improve method layout 2012-06-19 23:13:59 -07:00
Akash Manohar J
481d8110f2 Moves classes to seperate files
Signed-off-by: Akash Manohar J <akash@akash.im>
2012-05-15 02:38:09 +05:30