Skip to content

Commit

Permalink
fix up not found error exception messages
Browse files Browse the repository at this point in the history
  • Loading branch information
edaniels committed Apr 4, 2024
1 parent 97dadd1 commit 979fd8d
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,6 @@ public class ModelNotFoundException extends StatusRuntimeException {

public ModelNotFoundException(final Subtype subtype, final Model model) {
super(Status.NOT_FOUND.withDescription(
String.format("No %s with subtype \"%s\" found in the registry", subtype, model)));
String.format("No %s with model \"%s\" found in the registry", subtype, model)));
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,9 @@ public class ResourceSubtypeNotFoundException extends StatusRuntimeException {

public ResourceSubtypeNotFoundException(final Subtype subtype) {
super(Status.NOT_FOUND.withDescription(
String.format("No %s with subtype \"%s\" found in the registry", subtype.getResourceType(),
String.format(
"No %s with subtype \"%s\" found in the registry; did you forget to call Registry.registerSubtype?",
subtype.getResourceType(),
subtype.getResourceSubtype())));
}
}

0 comments on commit 979fd8d

Please sign in to comment.