Commit 6fc635dd authored by Eleo Basili's avatar Eleo Basili
Browse files

Issue #3276126 by eleonel: Use Json::encode instead of json_encode.

parent e4d86803
Loading
Loading
Loading
Loading
+2 −1
Original line number Diff line number Diff line
@@ -9,6 +9,7 @@ use Drupal\Core\Utility\Error;
use Psr\Log\LoggerInterface;
use Symfony\Component\DependencyInjection\ContainerInterface;
use Drupal\mailchimp\ClientFactory;
use Drupal\Component\Serialization\Json;

/**
 * Plugin implementation of the datasource.
@@ -274,7 +275,7 @@ Other shell wildcards such as ., ?, !, [] are honored for advanced users."));
          continue;
        }
        elseif (is_array($field_value) || is_object($field_value)) {
          $field_value = json_encode($field_value);
          $field_value = Json::encode($field_value);
        }

        $return_cookies[] = $this->createCookie($field_name, $field_value);