Skip to content
Snippets Groups Projects
Commit 1ec1d44e authored by johntarling's avatar johntarling Committed by John Ferris
Browse files

Issue #3508661: Ajax error when adding some paragraph types

parent 0a280622
No related branches found
No related tags found
1 merge request!112Issue #3508661: Ajax error when adding some paragraph types
......@@ -36,7 +36,7 @@ class MercuryEditorPreviewCacheContext extends RouteNameCacheContext {
* {@inheritdoc}
*/
public function getContext() {
if ($this->mercuryEditorContext->isPreview()) {
if ($this->mercuryEditorContext->isPreview() && $this->mercuryEditorContext->getEntity()) {
$entity = $this->mercuryEditorContext->getEntity();
return 'is_mercury_editor_preview.' . $entity->getEntityTypeId() . '.' . $entity->uuid();
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment