Fix issue with card update when no previous card
This commit is contained in:
1 parent
0d2e0dc752
commit
7170728177
2 files changed
+6
-6
No files matched your search
+1
-1
@@ -76,7 +76,7 @@ if($_SERVER['REQUEST_METHOD'] === 'POST') {
|
||||
return_json_response(array('error' => "User with user_id '".$data['user_id']."' does not exist."), 400);
|
||||
}
|
||||
$user = $user_data[0];
|
||||
$active_card_number = get_active_card_number($user);
|
||||
$active_card_number = get_active_card_number($user['cards']);
|
||||
|
||||
/* If card number is attached to specified user, bail */
|
||||
if($active_card_number && $active_card_number === $data['card_number']) {
|
||||
|
||||
Reference in new issue
Block a user