repositories
/
e-mobility-charging-stations-simulator.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
8f3233c
)
refactor: refine error type in helper
author
Jérôme Benoit
<jerome.benoit@sap.com>
Sun, 2 Jul 2023 22:37:00 +0000
(
00:37
+0200)
committer
Jérôme Benoit
<jerome.benoit@sap.com>
Sun, 2 Jul 2023 22:37:00 +0000
(
00:37
+0200)
Signed-off-by: Jérôme Benoit <jerome.benoit@sap.com>
src/utils/Utils.ts
patch
|
blob
|
blame
|
history
diff --git
a/src/utils/Utils.ts
b/src/utils/Utils.ts
index 647edcb9f88ad6b2674d8b82a051b75a443bba18..fb4492139e8367ff16634af861e51e4d1cf9c106 100644
(file)
--- a/
src/utils/Utils.ts
+++ b/
src/utils/Utils.ts
@@
-166,7
+166,7
@@
export class Utils {
scale = 2
): number {
if (fluctuationPercent < 0 || fluctuationPercent > 100) {
- throw new Error(
+ throw new
Range
Error(
`Fluctuation percent must be between 0 and 100. Actual value: ${fluctuationPercent}`
);
}