if ($profile instanceof ImportExportProfileEntity
) { return $profile;
} throw new ProfileNotFoundException($profileId);
} private function checkAllowedReadPrivileges(ImportExportProfileEntity
$profile, Context
$context): void
{ $missingPrivileges =
[];
$sourceEntity =
$profile->
getSourceEntity();
$privilege =
sprintf('%s:%s',
$sourceEntity, AclRoleDefinition::PRIVILEGE_READ
);
if (!
$context->
isAllowed($privilege)) { $missingPrivileges[] =
$privilege;
} $definition =
$this->definitionInstanceRegistry->
getByEntityName($sourceEntity);
$mappings =
$profile->
getMapping() ??
[];
$mappedKeys =
array_column($mappings, 'key'
);
$propertyPaths =
array_map(fn (string
$key): array =>
explode('.',
$key),
$mappedKeys);