@iblai/data-layer 1.28.0 → 1.29.0

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.esm.js CHANGED
@@ -42296,7 +42296,8 @@ const chatPrivacyApiSlice = createApi({
42296
42296
  reducerPath: 'chatPrivacyApiSlice',
42297
42297
  // Callers read the failure itself: the 403 a locked mentor answers to a
42298
42298
  // `disable-chathistory` flip carries its reason in `data.detail`, and the
42299
- // one-way 400 carries it under the field name. `iblFetchBaseQuery` throws
42299
+ // 400 refusing to re-enable an orphaned session carries it under the field
42300
+ // name. `iblFetchBaseQuery` throws
42300
42301
  // its errors, which reach `.unwrap()` and the hooks as `{}`.
42301
42302
  baseQuery: withReturnedErrors(iblFetchBaseQuery),
42302
42303
  tagTypes: ['TenantChatPrivacyConfig', 'UserChatPrivacySettings', 'ChatPrivacyEffective'],
@@ -42348,10 +42349,11 @@ const chatPrivacyApiSlice = createApi({
42348
42349
  },
42349
42350
  providesTags: ['ChatPrivacyEffective'],
42350
42351
  }),
42351
- // One-way switch: flipping a session to disable_chathistory: true also
42352
- // removes it from the user's history list (backend nulls Session.student).
42353
- // Per the spec, true → false is rejected with 400; the user must start a
42354
- // new conversation to resume history.
42352
+ // Two-way flip. `true` stops saving new messages; a session that already
42353
+ // has history keeps its owner (stays listed), an EMPTY one is orphaned
42354
+ // (backend nulls Session.student). `false` resumes history on the same
42355
+ // session, refused only for an orphaned session (400 for an admin, 404
42356
+ // for its own user — the ownership check fails first).
42355
42357
  //
42356
42358
  // Important — this endpoint lives under `/api/ai-mentor/…`, NOT under
42357
42359
  // `/api/ai-account/…` like the other chat-privacy endpoints. The