Restored some missing changes from an earlier commit
@@ -369,7 +369,7 @@ public class StreamsRegistryStorage extends AbstractRegistryStorage {
public CompletionStage<ArtifactMetaDataDto> createArtifactWithMetadata(String artifactId, ArtifactType artifactType, ContentHandle content, EditableArtifactMetaDataDto metaData) throws ArtifactAlreadyExistsException, RegistryStorageException {
return createArtifact(artifactId, artifactType, content)
.thenCompose(amdd -> submitter.submitMetadata(Str.ActionType.UPDATE, artifactId, -1, metaData.getName(), metaData.getDescription(), metaData.getLabels(), metaData.getProperties())
- .thenApply(v -> DtoUtil.setEditableMetaDataInArtifact((ArtifactMetaDataDto) amdd, metaData)));
+ .thenApply(v -> DtoUtil.setEditableMetaDataInArtifact(amdd, metaData)));
}
@Override
@@ -440,7 +440,7 @@ public class StreamsRegistryStorage extends AbstractRegistryStorage {
public CompletionStage<ArtifactMetaDataDto> updateArtifactWithMetadata(String artifactId, ArtifactType artifactType, ContentHandle content, EditableArtifactMetaDataDto metaData) throws ArtifactAlreadyExistsException, RegistryStorageException {
return updateArtifact(artifactId, artifactType, content)
.thenCompose(amdd -> submitter.submitMetadata(Str.ActionType.UPDATE, artifactId, -1, metaData.getName(), metaData.getDescription(), metaData.getLabels(), metaData.getProperties())
- .thenApply(v -> DtoUtil.setEditableMetaDataInArtifact((ArtifactMetaDataDto) amdd, metaData)));
+ .thenApply(v -> DtoUtil.setEditableMetaDataInArtifact(amdd, metaData)));
}
