repositories
/
e-mobility-charging-stations-simulator.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
refactor(ui): use watchers to refresh display
[e-mobility-charging-stations-simulator.git]
/
src
/
charging-station
/
Bootstrap.ts
diff --git
a/src/charging-station/Bootstrap.ts
b/src/charging-station/Bootstrap.ts
index 0c1eeeecb0386a009fba09797b02db651b15ea6e..80470d00f3e5069dcf498111f32cc8b28f009a02 100644
(file)
--- a/
src/charging-station/Bootstrap.ts
+++ b/
src/charging-station/Bootstrap.ts
@@
-537,6
+537,11
@@
export class Bootstrap extends EventEmitter {
templateFile: string,
options?: ChargingStationOptions
): Promise<void> {
templateFile: string,
options?: ChargingStationOptions
): Promise<void> {
+ if (!this.started && !this.starting) {
+ throw new BaseError(
+ 'Cannot add a charging station while charging stations simulator is not started'
+ )
+ }
await this.workerImplementation?.addElement({
index,
templateFile: join(
await this.workerImplementation?.addElement({
index,
templateFile: join(