Skip to content

Commit

Permalink
Fixing code smell with generic runtime exception.
Browse files Browse the repository at this point in the history
  • Loading branch information
SoLetsDev committed Nov 28, 2023
1 parent 24ae1c9 commit 52f6361
Showing 1 changed file with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
package ca.bc.gov.educ.penreg.api.service;

import ca.bc.gov.educ.penreg.api.exception.PenRegAPIRuntimeException;
import ca.bc.gov.educ.penreg.api.model.v1.PenRequestBatchMultiplePen;
import ca.bc.gov.educ.penreg.api.model.v1.Saga;
import ca.bc.gov.educ.penreg.api.model.v1.SagaEvent;
Expand Down Expand Up @@ -102,7 +103,7 @@ public void updateAttachedSagaWithEvents(final Saga saga, final SagaEvent sagaEv
}
} catch (Exception e) {
log.error("updateAttachedSagaWithEvents failed for PenRequestBatchId :: {}, SagaId :: {}, SagaEventState :: {}, Error :: {}", saga.getPenRequestBatchID(), saga.getSagaId(), sagaEvent.getSagaEventState(), e.toString());
throw new RuntimeException(e);
throw new PenRegAPIRuntimeException(e);
}
}

Expand Down

0 comments on commit 52f6361

Please sign in to comment.