@stream-io/video-client 0.7.6 → 0.7.7

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@stream-io/video-client",
3
- "version": "0.7.6",
3
+ "version": "0.7.7",
4
4
  "packageManager": "yarn@3.2.4",
5
5
  "main": "dist/index.cjs.js",
6
6
  "module": "dist/index.es.js",
package/src/Call.ts CHANGED
@@ -1939,9 +1939,8 @@ export class Call {
1939
1939
  if (rating < 1 || rating > 5) {
1940
1940
  throw new Error('Rating must be between 1 and 5');
1941
1941
  }
1942
- const userSessionId = this.sfuClient?.sessionId;
1943
1942
  const callSessionId = this.state.session?.id;
1944
- if (!callSessionId || !userSessionId) {
1943
+ if (!callSessionId) {
1945
1944
  throw new Error(
1946
1945
  'Feedback can be submitted only in the context of a call session',
1947
1946
  );
@@ -1951,6 +1950,9 @@ export class Call {
1951
1950
  getClientDetails(),
1952
1951
  );
1953
1952
 
1953
+ // user sessionId is not available once the call has been left
1954
+ // until we relax the backend validation, we'll send N/A
1955
+ const userSessionId = this.sfuClient?.sessionId ?? 'N/A';
1954
1956
  const endpoint = `${this.streamClientBasePath}/feedback/${callSessionId}`;
1955
1957
  return this.streamClient.post<
1956
1958
  CollectUserFeedbackResponse,