Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add support for the File Link resource #483

Merged
merged 1 commit into from
Aug 2, 2018
Merged

Conversation

remi-stripe
Copy link
Contributor

r? @ob-stripe @brandur-stripe
cc @stripe/api-libraries

@brandur-stripe
Copy link
Contributor

Minor comment, but otherwise LGTM.

Copy link
Contributor

@brandur-stripe brandur-stripe left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

(And oops, forgot to submit this review.)

Disputes: require('./resources/Issuing/Disputes'),
Transactions: require('./resources/Issuing/Transactions'),
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hah, thanks for alphabetizing everything!

stripe.fileLinks.update('fl_123', {metadata: {key: 'value'}});
expect(stripe.LAST_REQUEST).to.deep.equal({
method: 'POST',
url: '/v1/file_links/fl_123',
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Quite minor and I didn't notice on your PHP pull, but file link tokens have a test or live in them. This is unlike most resources, but is needed because you're not using a key that would hint which mode to load it in.

It might be slightly more accurate if we used an identifier like fl_live_123.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Wait, that's only for the url attribute though. File links have a regular token, but it starts with link_, not with fl_.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Oh oops. Yeah you're right — I got confused seeing the fl_.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

totally misread that from an earlier link I saw that had fl in it. Thanks for catching, I'll also fix in PHP

@remi-stripe
Copy link
Contributor Author

@brandur-stripe Fixed PTAL

@brandur-stripe
Copy link
Contributor

LGTM.

@brandur-stripe brandur-stripe merged commit 43bfe34 into master Aug 2, 2018
@brandur-stripe brandur-stripe deleted the remi-add-file-link branch August 2, 2018 22:58
@brandur-stripe
Copy link
Contributor

Released as 6.6.0.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants