Skip to content

Commit

Permalink
chore: rename property
Browse files Browse the repository at this point in the history
  • Loading branch information
shpran committed Feb 13, 2025
1 parent a38fa72 commit 176d271
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions model/qti/metadata/ontology/MappedMetadataInjector.php
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ public function __construct(ListService $listService)

public function inject(array $mappedProperties, array $metadataValues, Resource $resource): void
{
$purifiedProperties = [];
$removedProperties = [];

/** @var SimpleMetadataValue $metadataValue */
foreach ($metadataValues as $metadataValue) {
Expand Down Expand Up @@ -80,9 +80,9 @@ public function inject(array $mappedProperties, array $metadataValues, Resource
if ($mappedProperties[$mappedPath]->getRange() !== null) {
$propertyUri = $mappedProperties[$mappedPath]->getUri();

if (!in_array($propertyUri, $purifiedProperties, true)) {
if (!in_array($propertyUri, $removedProperties, true)) {
$resource->removePropertyValues($mappedProperties[$mappedPath]);
$purifiedProperties[] = $propertyUri;
$removedProperties[] = $propertyUri;
}

$this->setListValue($mappedProperties[$mappedPath], $resource, $metadataValue);
Expand Down

0 comments on commit 176d271

Please sign in to comment.