Skip to content

Commit 8354e93

Browse files
saxenakshitizsaxenakshitiz
andauthored
chore: fix delete application rule error case (#279)
Co-authored-by: saxenakshitiz <kshitiz@traceable.ai>
1 parent 27df06f commit 8354e93

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

label-application-rule-config-service-impl/src/main/java/org/hypertrace/label/application/rule/config/service/LabelApplicationRuleConfigServiceImpl.java

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -164,8 +164,9 @@ public void deleteLabelApplicationRule(
164164
if (customRuleDeleted || systemLabelApplicationRule.isPresent()) {
165165
responseObserver.onNext(DeleteLabelApplicationRuleResponse.getDefaultInstance());
166166
responseObserver.onCompleted();
167+
} else {
168+
throw Status.NOT_FOUND.asRuntimeException();
167169
}
168-
throw Status.NOT_FOUND.asRuntimeException();
169170
} catch (Exception e) {
170171
responseObserver.onError(e);
171172
}

0 commit comments

Comments
 (0)