field_permissions_group-3256683/'3256683-error-when-using
check that $membership is not FALSE
in field_permissions_group\Plugin\FieldPermissionType\CustomGroupAccess::hasFieldAccess before trying to access the $membership->hasPermission method.
This change prevents the following error:
Call to a member function hasPermission() on bool in Drupal\field_permissions_group\Plugin\FieldPermissionType\CustomGroupAccess->hasFieldAccess() (line 148 of /web/modules/contrib/field_permissions_group/src/Plugin/FieldPermissionType/CustomGroupAccess.php)
Closes #3256683