0a1,26 > diff --git a/modules/preview_graphql_jwt/preview_graphql_jwt.module b/modules/preview_graphql_jwt/preview_graphql_jwt.module > index 8900b62..fc97f17 100644 > --- a/modules/preview_graphql_jwt/preview_graphql_jwt.module > +++ b/modules/preview_graphql_jwt/preview_graphql_jwt.module > @@ -28,7 +28,7 @@ function preview_graphql_jwt_help($route_name, RouteMatchInterface $route_match) > '#value' => $content, > ]; > $output = ''; > - $output .= render($build); > + $output .= \Drupal::service('renderer')->render($build); > return $output; > } > return ''; > diff --git a/preview_graphql.module b/preview_graphql.module > index 5a07b59..da6320c 100644 > --- a/preview_graphql.module > +++ b/preview_graphql.module > @@ -32,7 +32,7 @@ function preview_graphql_help($route_name, RouteMatchInterface $route_match) { > '#value' => $content, > ]; > $output = ''; > - $output .= render($build); > + $output .= \Drupal::service('renderer')->render($build); > return $output; > } > return ''; 2c28 < index 2976fe7..7bcd534 100644 --- > index 2976fe7..cd8a1a9 100644 5,10c31 < @@ -9,7 +9,7 @@ use Symfony\Component\EventDispatcher\Event; < * < * @see \Drupal\preview_graphql\Form\SettingsForm. < */ < -class CarrierCallbackOptionEvent extends Event { < +class CarrierCallbackOptionEvent extends \Symfony\Contracts\EventDispatcher\Event { --- > @@ -2,7 +2,7 @@ 12c33 < const EVENT_NAME = 'preview_graphql.carrier_callback_option'; --- > namespace Drupal\preview_graphql\Event; 13a35,39 > -use Symfony\Component\EventDispatcher\Event; > +use Symfony\Contracts\EventDispatcher\Event; > > /** > * Event that is fired when settings of carrier callback element is building. 15c41 < index e636cd4..27b8540 100644 --- > index e636cd4..0b6d0eb 100644 18c44,50 < @@ -7,7 +7,7 @@ use Symfony\Component\EventDispatcher\Event; --- > @@ -2,7 +2,7 @@ > > namespace Drupal\preview_graphql\Event; > > -use Symfony\Component\EventDispatcher\Event; > +use Symfony\Contracts\EventDispatcher\Event; > 21,26c53,65 < */ < -abstract class PreviewGraphQlEventBase extends Event { < +abstract class PreviewGraphQlEventBase extends \Symfony\Contracts\EventDispatcher\Event { < < /** < * The type carrier callback key. --- > diff --git a/src/Plugin/GraphQL/Fields/PreviewGraphQLField.php b/src/Plugin/GraphQL/Fields/PreviewGraphQLField.php > index 6b49456..ceaba26 100644 > --- a/src/Plugin/GraphQL/Fields/PreviewGraphQLField.php > +++ b/src/Plugin/GraphQL/Fields/PreviewGraphQLField.php > @@ -69,7 +69,7 @@ class PreviewGraphQLField extends FieldPluginBase implements ContainerFactoryPlu > $event = new ContextResolverCacheEvent($carrier_callback, $context); > $this->previewGraphQLManager->getPreviewGraphQlBackend() > ->getEventDispatcher() > - ->dispatch(ContextResolverCacheEvent::EVENT_NAME, $event); > + ->dispatch($event, ContextResolverCacheEvent::EVENT_NAME); > $result = $this->previewGraphQLManager->getCacheDataValue('gql'); > if (is_array($result) && !empty($result['error'])) { > throw new Error(sprintf('%s', $result['error']));