@speakableio/core 1.0.55 → 1.0.57

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.
@@ -1702,7 +1702,7 @@ var BASE_RESPOND_FIELD_VALUES = {
1702
1702
  title: "",
1703
1703
  allowRetries: true,
1704
1704
  respondTime: 180,
1705
- maxCharacters: 1e3
1705
+ maxCharacters: 1e4
1706
1706
  };
1707
1707
  var BASE_REPEAT_FIELD_VALUES = {
1708
1708
  repeat: 1
@@ -3286,11 +3286,16 @@ var useUpdateStudentVocab = (page) => {
3286
3286
  try {
3287
3287
  await api.updateDoc(docPath, data);
3288
3288
  } catch (error) {
3289
- if (error instanceof Error && error.message === "not-found") {
3290
- data.firstSeen = serverTimestamp2();
3291
- await api.setDoc(docPath, data, { merge: true });
3289
+ if (error instanceof Error && "code" in error) {
3290
+ const firebaseError = error;
3291
+ if (firebaseError.code === "not-found") {
3292
+ data.firstSeen = serverTimestamp2();
3293
+ await api.setDoc(docPath, data, { merge: true });
3294
+ } else {
3295
+ console.error("Error actualizando vocabulario:", error);
3296
+ }
3292
3297
  } else {
3293
- console.log(error);
3298
+ console.error("Error desconocido:", error);
3294
3299
  }
3295
3300
  }
3296
3301
  try {