mirror of
https://github.com/brendan-ch/project-inter-server.git
synced 2026-04-17 07:50:31 +00:00
Change the event name to SHUTTLE_WILL_ARRIVE_AT_STOP, and emit it before the stop is updated
This commit is contained in:
@@ -401,8 +401,8 @@ export class RedisShuttleRepository extends BaseRedisRepository implements Shutt
|
||||
timestamp: new Date(travelTimeTimestamp),
|
||||
shuttleId: shuttle.id,
|
||||
};
|
||||
this.emit(ShuttleRepositoryEvent.SHUTTLE_WILL_ARRIVE_AT_STOP, shuttleArrival);
|
||||
await this.updateShuttleLastStopArrival(shuttleArrival);
|
||||
this.emit(ShuttleRepositoryEvent.SHUTTLE_ARRIVED_AT_STOP, shuttleArrival);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user