Skip to content

Commit

Permalink
fix(api-v2): Clarify error message.
Browse files Browse the repository at this point in the history
  • Loading branch information
Benjamin Geer committed Nov 27, 2019
1 parent 49b2d4f commit b4acacf
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -1298,7 +1298,7 @@ class ResourcesResponderV2(responderData: ResponderData) extends ResponderWithSt
resource: ReadResourceV2 = resources.toResource(gravsearchTemplateIri)

_ = if (resource.resourceClassIri.toString != OntologyConstants.KnoraBase.TextRepresentation) {
throw BadRequestException(s"Resource $gravsearchTemplateIri is not a text file")
throw BadRequestException(s"Resource $gravsearchTemplateIri is not a Gravsearch template (text file expected)")
}

gravsearchFileValueContent: TextFileValueContentV2 = resource.values.get(OntologyConstants.KnoraBase.HasTextFileValue.toSmartIri) match {
Expand Down

0 comments on commit b4acacf

Please sign in to comment.