mindcache 3.5.0 → 3.5.1

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.
@@ -394,10 +394,12 @@ var init_CloudAdapter = __esm({
394
394
  try {
395
395
  if (typeof event.data === "string") {
396
396
  const msg = JSON.parse(event.data);
397
+ console.log("\u2601\uFE0F CloudAdapter: Received JSON message:", msg.type, msg);
397
398
  if (msg.type === "auth_success") {
398
399
  this._state = "connected";
399
400
  this.reconnectAttempts = 0;
400
401
  this.emit("connected");
402
+ console.log("\u2601\uFE0F Connected to MindCache cloud");
401
403
  } else if (msg.type === "auth_error" || msg.type === "error") {
402
404
  this._state = "error";
403
405
  this.emit("error", new Error(msg.error));
@@ -405,6 +407,7 @@ var init_CloudAdapter = __esm({
405
407
  console.debug("MindCache Cloud: Received message type:", msg.type, msg);
406
408
  }
407
409
  } else {
410
+ console.log("\u2601\uFE0F CloudAdapter: Received binary message, length:", event.data.byteLength);
408
411
  const encoder = encoding__namespace.createEncoder();
409
412
  const decoder = decoding__namespace.createDecoder(new Uint8Array(event.data));
410
413
  if (this.mindcache) {
@@ -415,6 +418,7 @@ var init_CloudAdapter = __esm({
415
418
  if (!this._synced && (messageType === 1 || messageType === 2)) {
416
419
  this._synced = true;
417
420
  this.emit("synced");
421
+ console.log("\u2601\uFE0F Synced with cloud");
418
422
  }
419
423
  }
420
424
  }