stream-chat
Advanced tools
Comparing version 8.16.0 to 8.17.0
{ | ||
"name": "stream-chat", | ||
"version": "8.16.0", | ||
"version": "8.17.0", | ||
"description": "JS SDK for the Stream Chat API", | ||
@@ -97,3 +97,3 @@ "author": "GetStream", | ||
"husky": "^4.3.8", | ||
"lint-staged": "^10.5.4", | ||
"lint-staged": "^15.2.2", | ||
"mocha": "^9.1.3", | ||
@@ -128,2 +128,3 @@ "nyc": "^15.1.0", | ||
"lint-fix": "yarn run prettier-fix && yarn run eslint-fix", | ||
"fix-staged": "lint-staged --config .lintstagedrc.fix.json --concurrent 1", | ||
"prepare": "yarn run build", | ||
@@ -134,7 +135,2 @@ "preversion": "yarn && yarn lint && yarn test-unit", | ||
}, | ||
"husky": { | ||
"hooks": { | ||
"pre-commit": "yarn run lint" | ||
} | ||
}, | ||
"engines": { | ||
@@ -141,0 +137,0 @@ "node": ">=16" |
@@ -401,3 +401,15 @@ import { ChannelState } from './channel_state'; | ||
); | ||
const areCapabilitiesChanged = | ||
[...(data.channel.own_capabilities || [])].sort().join() !== | ||
[...(Array.isArray(this.data?.own_capabilities) ? (this.data?.own_capabilities as string[]) : [])].sort().join(); | ||
this.data = data.channel; | ||
// If the capabiltities are changed, we trigger the `capabilities.changed` event. | ||
if (areCapabilitiesChanged) { | ||
this.getClient().dispatchEvent({ | ||
type: 'capabilities.changed', | ||
cid: this.cid, | ||
own_capabilities: data.channel.own_capabilities, | ||
}); | ||
} | ||
return data; | ||
@@ -712,3 +724,3 @@ } | ||
if (!this.getConfig()?.read_events) { | ||
if (!this.getConfig()?.read_events && !this.getClient()._isUsingServerAuth()) { | ||
return Promise.resolve(null); | ||
@@ -731,3 +743,3 @@ } | ||
if (!this.getConfig()?.read_events) { | ||
if (!this.getConfig()?.read_events && !this.getClient()._isUsingServerAuth()) { | ||
return Promise.resolve(null); | ||
@@ -734,0 +746,0 @@ } |
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
5378077
56081