@mozaik-ai/core 4.2.0-beta.7 → 4.2.0-beta.8

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.mjs CHANGED
@@ -205,9 +205,6 @@ var Space = class _Space {
205
205
  }
206
206
  getParticipant(id) {
207
207
  const participant = this.getParticipants().find((p) => p.getId() === id);
208
- if (!participant) {
209
- throw new Error(`Participant ${id} not found`);
210
- }
211
208
  return participant;
212
209
  }
213
210
  removeParticipant(participant) {
@@ -281,13 +278,13 @@ function defineRuntime() {
281
278
  const createSpace = async (name) => {
282
279
  return await createSpaceUseCase.execute(name);
283
280
  };
284
- const participantJoinedUseCase = new ParticipantJoinUseCase(spaceRepository, eventPublisher);
281
+ const participantJoinUseCase = new ParticipantJoinUseCase(spaceRepository, eventPublisher);
285
282
  const join = async (spaceId, participant) => {
286
- return await participantJoinedUseCase.execute(spaceId, participant);
283
+ return await participantJoinUseCase.execute(spaceId, participant);
287
284
  };
288
- const participantLeftUseCase = new ParticipantLeaveUseCase(spaceRepository, eventPublisher);
285
+ const participantLeaveUseCase = new ParticipantLeaveUseCase(spaceRepository, eventPublisher);
289
286
  const leave = async (spaceId, participantId) => {
290
- return await participantLeftUseCase.execute(spaceId, participantId);
287
+ return await participantLeaveUseCase.execute(spaceId, participantId);
291
288
  };
292
289
  const sendMessageUseCase = new SendMessageUseCase(spaceRepository, eventPublisher);
293
290
  const sendMessage = async (spaceId, participantId, message) => {