Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
Stripe
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container registry
Model registry
Operate
Environments
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Extensions
Stripe
Commits
2efff690
Commit
2efff690
authored
6 years ago
by
mattwire
Browse files
Options
Downloads
Patches
Plain Diff
Add http response codes
parent
5ade3db1
Branches
Branches containing commit
Tags
Tags containing commit
1 merge request
!11
Support Cancellation and major refactor of backend / webhook processing
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
CRM/Core/Payment/Stripe.php
+1
-0
1 addition, 0 deletions
CRM/Core/Payment/Stripe.php
CRM/Core/Payment/StripeIPN.php
+2
-4
2 additions, 4 deletions
CRM/Core/Payment/StripeIPN.php
with
3 additions
and
4 deletions
CRM/Core/Payment/Stripe.php
+
1
−
0
View file @
2efff690
...
...
@@ -870,6 +870,7 @@ class CRM_Core_Payment_Stripe extends CRM_Core_Payment {
$data
=
json_decode
(
$data_raw
);
$ipnClass
=
new
CRM_Core_Payment_StripeIPN
(
$data
);
$ipnClass
->
main
();
http_response_code
(
200
);
}
...
...
This diff is collapsed.
Click to expand it.
CRM/Core/Payment/StripeIPN.php
+
2
−
4
View file @
2efff690
...
...
@@ -240,7 +240,6 @@ class CRM_Core_Payment_StripeIPN extends CRM_Core_Payment_BaseIPN {
}
else
{
// The first contribution was completed, so create a new one.
// api contribution repeattransaction repeats the appropriate contribution if it is given
// simply the recurring contribution id. It also updates the membership for us.
civicrm_api3
(
'Contribution'
,
'repeattransaction'
,
array
(
...
...
@@ -260,7 +259,6 @@ class CRM_Core_Payment_StripeIPN extends CRM_Core_Payment_BaseIPN {
'failure_count'
=>
0
,
'contribution_status_id'
=>
'In Progress'
));
return
;
// Failed recurring payment.
...
...
@@ -489,7 +487,7 @@ class CRM_Core_Payment_StripeIPN extends CRM_Core_Payment_BaseIPN {
public
function
exception
(
$message
)
{
$errorMessage
=
'StripeIPN Exception: Event: '
.
$this
->
event_type
.
' Error: '
.
$message
;
Civi
::
log
()
->
debug
(
$errorMessage
);
//throw new CRM_Core_Exception($errorMessage
);
exit
();
http_response_code
(
400
);
exit
(
1
);
}
}
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment