Skip to content

Commit

Permalink
Fix conflict with main
Browse files Browse the repository at this point in the history
  • Loading branch information
EricWittmann committed Mar 5, 2024
1 parent d5d04d2 commit 02ca79f
Showing 1 changed file with 1 addition and 7 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@
import io.apicurio.registry.storage.dto.ArtifactVersionMetaDataDto;
import io.apicurio.registry.storage.dto.ContentWrapperDto;
import io.apicurio.registry.storage.dto.StoredArtifactVersionDto;
import io.apicurio.registry.storage.error.ArtifactNotFoundException;
import io.apicurio.registry.types.ArtifactType;
import io.apicurio.registry.types.VersionState;
import io.apicurio.registry.util.ArtifactTypeUtil;
Expand All @@ -40,13 +39,8 @@ public SchemaInfo getSchema(int id, String subject, String groupId) {
references = artifactVersion.getReferences();
} else {
ContentWrapperDto contentWrapper = storage.getContentById(id);
contentHandle = storage.getContentById(id).getContent();
contentHandle = contentWrapper.getContent();
references = contentWrapper.getReferences();
List<ArtifactVersionMetaDataDto> artifacts = storage.getArtifactVersionsByContentId(id);
if (artifacts == null || artifacts.isEmpty()) {
//the contentId points to an orphaned content
throw new ArtifactNotFoundException("ContentId: " + id);
}
}
return converter.convert(contentHandle, ArtifactTypeUtil.determineArtifactType(contentHandle, null, null,
storage.resolveReferences(references), factory.getAllArtifactTypes()), references);
Expand Down

0 comments on commit 02ca79f

Please sign in to comment.