-
Notifications
You must be signed in to change notification settings - Fork 63
In-app payment methods #58
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
Closed
Closed
Changes from all commits
Commits
Show all changes
12 commits
Select commit
Hold shift + click to select a range
aaa099d
renamed appsecret config into app_secret
gr8bit 6e2d2de
added app_id config and app_access_token accessor
gr8bit 347bf69
added payment method
gr8bit f9ed079
added payment test without fields
gr8bit 521e0ef
added facebook reference link
gr8bit 87ab7c3
payment dispute settling function added
gr8bit 0ae0b38
added refunds method
gr8bit 1dd13f3
cleanup
gr8bit 89b28f9
satisfy 80 char line length limitation
gr8bit 21683be
added functions to create, verify and decode signed requests
gr8bit d072ac6
renamed dispute and refunds methods, removed unnecessary guards
gr8bit 5242fb9
fixed app_access_token() by introducing new parameter, minor cleanups
gr8bit File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
IMO this should be doable in a simpler way.
What's the purpose of the guard in the function? If
signed_requestis not a binary and you call that function then there won't be another function executed instead.Also why the
withwith another guard (if you split a binary it should still be a binary)?There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm quite new to Elixir, maybe it really can be done better: I used the inner guards to ensure there won't be nil values. Which, you're right, is complete nonsense in the case of split() as it doesn't return nil values. I'll remove them.
However, guard'ing the function itself prevents it from being called with a wrong value and raise an exception instead of trying to call split() with a wrong argument. What do you think about that? How could I do it better?