734 Commits

Author SHA1 Message Date
Brandur
c3c541363b Bump version to 1.36.2 v1.36.2 2016-03-14 07:25:28 -07:00
Brandur
5c999c3100 Merge pull request #396 from stripe/brandur-fix-list
Fix reference to URLs on ListObject
2016-03-14 07:24:14 -07:00
Brandur
0311b4a7cd Fix reference to URLs on ListObject
In #394 we renamed `url` to `resource_url` in order to prevent name
collisions in API resource that also have a `url` property.
Unfortunately, this didn't account for the fact that when making API
calls on a list object we rely on a returned `url` property to build a
request, and this had been renamed to `resource_url`. Test should have
caught this, but they were written to work differently than how live
API calls actually function.

This patch repairs the problem by adding a `resource_url` to list
objects, and modifies test to be more accurate to reality so that
they'll catch this class of problem in the future.

Fixes #395.
2016-03-14 06:52:26 -07:00
Brandur
f612aa9057 Merge pull request #394 from shekibobo/feature/resource-url
Fix ApiResource resource URL clashing with user-defined URL properties. Fixes #393.
2016-03-11 11:23:00 -08:00
Joshua Kovach
e226ef2ea1 Change everything from url to resource_url 2016-03-11 02:53:50 -05:00
Brandur
7849e844cd Merge pull request #390 from stripe/brandur-refactor-serialize-params
Refactor `serialize_params` under `StripeObject`
2016-03-07 11:41:48 -08:00
Brandur
b452835344 Fix spelling problem 2016-03-07 11:32:50 -08:00
Brandur
592bc89688 Refactor special case serialization for clarity 2016-03-07 11:27:45 -08:00
Brandur
dd11f4b297 Remove the ugly dirty == false 2016-03-07 11:11:57 -08:00
Brandur
27ebcbb697 Revert to opts = {} and rename to method_options 2016-03-07 09:59:33 -08:00
Brandur
eba117d5e8 Kill outdated "two" 2016-03-07 09:56:08 -08:00
Brandur
06cbe6239a Improve the accuracy on the comment above Hash serialization 2016-03-04 19:26:08 -08:00
Brandur
c173f802a6 Add comment about APIResource exclusion for clarity 2016-03-04 19:24:15 -08:00
Brandur
adcb806aac Add test to check .serialize_params deprecation 2016-03-04 19:22:17 -08:00
Brandur
f215827e2f Remove uses and deprecate .serialize_params 2016-03-04 19:18:26 -08:00
Brandur
fcfef21c77 Add spec for #dirty! 2016-03-04 19:10:59 -08:00
Brandur
f723080220 Refactor serialize_params under StripeObject
This pull does two major things:

1. Refactors `serialize_params` to be more concise and readable while
   still complying to our existing test suite. Unfortunately over time
   this method has become a ball of mud that's very difficult to reason
   about, as recently evidenced by #384.
2. Moves `serialize_params` from class method to instance method (while
   still keeping for old class method for backwards compatibility). This
   is to give it a more sane interface.
2016-03-04 19:04:29 -08:00
Brandur
fa314f6166 Bump version to 1.36.1 v1.36.1 2016-03-04 15:01:05 -08:00
Brandur
127c6694e8 Merge pull request #389 from stripe/brandur-fix-save-with-hash
Fix serialization of hashes passed to `#save`
2016-03-04 14:59:44 -08:00
Brandur
d92d084211 Add a few more low-level StripeObject tests 2016-03-04 14:52:30 -08:00
François de Metz
bc6cc96310 Fix serialization of hash when calling save.
Hashes are converted to StripeObject when used as params of save.
They need to be converted to hash on serialize.

Signed-off-by: François de Metz <francois@stormz.me>
Signed-off-by: Cyril Duez <cyril@stormz.me>
2016-03-04 14:40:57 -08:00
Brandur
abbf4c6426 Fix some gross trailing whitespace 2016-03-04 14:03:32 -08:00
Brandur
f711494f54 Merge pull request #387 from stripe/brandur-pass-params-fee-refund
Pass params and opts through on `ApplicationFee#refund`
2016-03-03 23:59:33 -08:00
Brandur
3fab2cd59f Pass params and opts through on ApplicationFee#refund
`params` and `opts` are not currently passed through when using the
`#refund` helper on `ApplicationFee`. This was an omission on the
original refactor to use the new endpoint, and wasn't an intentional
design.

Fixes #386.
2016-03-02 13:45:57 -08:00
Brandur
24632af95a Merge pull request #385 from stripe/brandur-md-readme
Change README to Markdown
2016-02-22 16:20:28 -08:00
Brandur
f7717208ae Change README to Markdown
This is kind of a bike shed, but at this point it's a little more clear
that Markdown has won the format wars and that people are a little more
used to seeing/editing it.

This moves the `README` to Markdown and also includes some minor
cleanup:

* Fixes a broken reference link (`curl`).
* Normalizes lines to 80 characters.
* Normalizes code snippets to be prefixed by four spaces.
* Normalizes sentence to be separately by only a single space.
2016-02-22 16:07:07 -08:00
Brandur
270dfe6052 Fix grammar problem 2016-02-19 10:28:03 -08:00
Brandur
eda056b9f6 Improve accuracy of puts message 2016-02-15 09:10:35 -08:00
Brandur
3e9cba3afd Merge pull request #380 from mohnish/master
Clean up stripe-console and use the IRB API
2016-02-15 09:09:29 -08:00
Mohnish Thallavajhula
07a27b61b6 Clean up stripe-console and use the IRB API 2016-02-14 09:43:24 -08:00
Brandur
097e185042 Merge pull request #379 from ahacop/remove-json
Remove json gem dependency
2016-02-09 12:04:33 -08:00
Ara Hacopian
c0ef16ad1d Remove json gem dependency
All required rubies include JSON as part of the stdlib.
2016-02-09 14:12:39 -05:00
Brandur
9b1315d08c Bump version to 1.36.0 v1.36.0 2016-02-08 08:24:04 -08:00
Brandur
85f191217b A few more nominal whitespace tweaks 2016-02-08 08:23:33 -08:00
Brandur
555341029b Tweak whitespace for consistency 2016-02-08 08:21:34 -08:00
Brandur
b2d74b09ff Merge pull request #376 from Easybring/master
support for country_spec
2016-02-08 08:19:36 -08:00
Ioannis Kolovos
f8532d225e Support for Stripe::CountrySpec 2016-02-06 16:55:29 +02:00
Brandur
3a258806a2 Bump version to 1.35.1 v1.35.1 2016-02-03 14:06:08 -08:00
Brandur
d8fc785f34 Merge pull request #374 from stripe/brandur-refund-fallback
Provide compatibility patch the Charge#refund helper
2016-02-03 14:04:54 -08:00
Brandur
65b92dec4b Provide compatibility patch the Charge#refund helper
An unfortunate side effect of #364 is that it broke compatibility for
users on very old API versions because their `refunds` field will come
back as an array.

This adds a compatibility layer that will allow even users on old API
versions to seamlessly upgrade their gem versions.
2016-02-03 13:45:01 -08:00
Brandur
23c61cc867 Bump version to 1.35.0 v1.35.0 2016-02-01 05:14:43 -08:00
Brandur
687be7015d Merge pull request #372 from stripe/brandur-update-bundle
Update CA bundle
2016-02-01 05:12:26 -08:00
Brandur
7aed899e1a Merge pull request #371 from stripe/brandur-configuration-ca-bundle-path
Allow the CA bundle to be configured
2016-02-01 05:12:14 -08:00
Brandur
31bbf02d4d Update CA bundle
Our CA bundle has fallen quite out of date since it was last pulled.
This patch updates it and adds a Rake task to make this task more
repeatable.

One thing worth noting is I've switched us over from the Ubuntu bundle
to the Mozilla bundle that's maintained by cURL. The bundle seemed to be
previously extracted by a custom script that I don't really want to
maintain. cURL and Excon both use the Mozilla bundle and it should be a
safe replacement.
2016-01-26 14:32:16 -08:00
Brandur
61ba47d619 Allow the CA bundle to be configured
As requested in #370, this will allow advanced users to configure a
certificate bundle that is expected to be more up-to-date than what
we've managed to include with the gem.
2016-01-26 14:19:07 -08:00
Brandur
91f42f4bc2 Bump version to 1.34.0 v1.34.0 2016-01-25 11:24:07 -08:00
Brandur
a508688c3c Merge pull request #368 from stripe/rasmus-support_product_sku_deletion
Support deleting SKUs and products.
2016-01-25 11:22:59 -08:00
Rasmus Rygaard
8d8fb67aae Support deleting SKUs and products. 2016-01-25 10:32:49 -08:00
Brandur
03086b8086 Bump version to 1.33.1 v1.33.1 2016-01-21 15:16:34 -08:00
Brandur
89cf6071b7 Merge pull request #366 from yogeshjain999/charge_refund_fix
Forward parameters passed to charge.refund
2016-01-21 11:54:33 -08:00