Skip to content

Commit d425593

Browse files
committed
Fixed uninitiated variable in stripe processing
1 parent f2786f8 commit d425593

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

src/Http/Requests/RecordStripeEvent.php

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -79,6 +79,7 @@ private function recordCharge(array $transaction, $user)
7979

8080
private function recordSubscription(array $transaction, $user, array $originalValues = [])
8181
{
82+
$trackingData = [];
8283
$planStatus = array_key_exists('status', $transaction) ? $transaction['status'] : null;
8384
$planName = isset($transaction['plan']['name']) ? $transaction['plan']['name'] : null;
8485
$planStart = array_key_exists('start', $transaction) ? $transaction['start'] : null;
@@ -169,9 +170,7 @@ private function recordSubscription(array $transaction, $user, array $originalVa
169170
}
170171
}
171172

172-
if ($trackingData) {
173-
event(new MixpanelEvent($user, $trackingData, 0, $profileData));
174-
}
173+
event(new MixpanelEvent($user, $trackingData, 0, $profileData));
175174
}
176175

177176
private function findStripeCustomerId(array $transaction)

0 commit comments

Comments
 (0)