I’m not sure when version 3.9.0 was released, but I was accessing forms with PayPal fields just fine earlier today. Now, trying to load the form editing screen causes a fatal error, and from that point on, the whole site is inaccessible until I manually deactivate the plugin in the file system.
Here’s the error:
PHP Fatal error: Uncaught TypeError: Cannot access offset of type string on string in [REDACTED]/wp-content/plugins/gravityformsppcp/includes/class-gf-ppcp-api.php:147
I haven’t dug deeper, but I think what’s happening is that the gf_ppcp()->maybe_decode_json() method is returning a string instead of an array. I was able to work around the problem by replacing the else statement with: if (!is_array($result_body))
I’m going to submit a support ticket too but I thought I would post it here in case anyone else is running into any new issues today with the PayPal add-on.
Also have this problem on multiple sites and I have just submitted it to the support team. I note that there is also an error reported when examining the paypal connection setup in the webhook section.
We have encountered the same errors with the webhook and critical error on form pages on some of our client sites as well. We’ve submitted a ticket for support as well. Glad we’re not the only ones in this boat, and hoping this gets resolved quickly!
After further investigation, the fatal error is being triggered by this PayPal incident which is preventing the add-ons proper communication with the PayPal REST API. Our support team is able to provide a hotfix build of the PayPal Add-On which adds a guard clause to prevent the fatal error.
Note: Until PayPal resolves the incident on their end, it is likely that transactions may not be accepted. This version simply prevents any related fatal errors resulting from their outage.