Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save jodyHamilton/525a873f7cb0d1669a1b158670da1eaf to your computer and use it in GitHub Desktop.
Save jodyHamilton/525a873f7cb0d1669a1b158670da1eaf to your computer and use it in GitHub Desktop.
diff --git a/src/FieldCollectionItemAccessControlHandler.php b/src/FieldCollectionItemAccessControlHandler.php
index 4c79e3d..41339d8 100644
--- a/src/FieldCollectionItemAccessControlHandler.php
+++ b/src/FieldCollectionItemAccessControlHandler.php
@@ -23,9 +23,13 @@ protected function checkAccess(EntityInterface $entity, $operation, AccountInter
}
// Here we will be if host entity was not set and entity is not new.
elseif (!$entity->isNew()) {
+ // Applications that were migrated throw errors on first save though
+ // the ui. This is a temporary work around for that.
+ /**
throw new \RuntimeException($this->t('Host entity for field collection item (@id) was not set.', [
'@id' => $entity->id(),
]));
+ */
}
}
Bypass error when saving migrated application.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment