Adding Tax to payment form errors
Description
Error thrown when adding Tax to a payment form. Tax has been created in Stripe and is shown in Stripe Payments but adding to the payment form throws the following error:
TypeError
in_array(): Argument #2 ($haystack) must be of type array, null given
1. in /home/bristolcrewco/stage.bristolcrew.co.uk/craft/vendor/enupal/stripe/src/services/Vendors.phpat line 89
80818283848586878889909192939495969798 $connect->rate = $settings->globalRate;
$connect->allProducts = false;
$connects = Stripe::$app->connects->getConnectsByVendorId($vendor->id, false);
if (!empty($connects)) {
$connect = $connects[0];
if (is_string($connect->products)){
$products = json_decode($connect->products, true);
$productId = "".$paymentForm->id;
if (!in_array($productId, $products)) {
$products[] = $productId;
} else {
return false;
}
}
}
$connect->products = json_encode($products);
'''



### Additional info
- Craft version: Craft Pro 4.5.9
- PHP version: 8.0.30
- Database driver & version: MySQL 5.7.43
- Plugin version: 5.5.0
- Is [SCA](https://docs.enupal.com/stripe-payments/getting-started/sca.html) and Stripe Checkout enabled?: YES
@andrelopez Just updating this - it seems making any change to a payment form or creating a new payment form causes this error...so payment forms can no longer be created at all...
Just to update this as per the error above this seems to be to do with Stripe Connect...I deleted all my connect data and turned off connect (turning off by its self didn't help) and now I am able to use payment forms again....
Thanks for following up and for sharing your findings