@cocreate/socket-server 1.3.2 → 1.3.3
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/CHANGELOG.md +7 -0
- package/package.json +1 -1
- package/src/index.js +2 -2
package/CHANGELOG.md
CHANGED
|
@@ -1,3 +1,10 @@
|
|
|
1
|
+
## [1.3.3](https://github.com/CoCreate-app/CoCreate-socket-server/compare/v1.3.2...v1.3.3) (2022-08-31)
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
### Bug Fixes
|
|
5
|
+
|
|
6
|
+
* renamed variable broadcast_sender to broadcastSender ([752c5f6](https://github.com/CoCreate-app/CoCreate-socket-server/commit/752c5f6b7ce850ab81883ee39ace9922093bcf5b))
|
|
7
|
+
|
|
1
8
|
## [1.3.2](https://github.com/CoCreate-app/CoCreate-socket-server/compare/v1.3.1...v1.3.2) (2022-07-25)
|
|
2
9
|
|
|
3
10
|
|
package/package.json
CHANGED
package/src/index.js
CHANGED
|
@@ -198,7 +198,7 @@ class SocketServer extends EventEmitter{
|
|
|
198
198
|
|
|
199
199
|
if (clients) {
|
|
200
200
|
clients.forEach((client) => {
|
|
201
|
-
if (socket != client || socket == client && data.
|
|
201
|
+
if (socket != client || socket == client && data.broadcastSender != false) {
|
|
202
202
|
if (isAsync) {
|
|
203
203
|
asyncData.push({socket: client, message: responseData})
|
|
204
204
|
} else {
|
|
@@ -214,7 +214,7 @@ class SocketServer extends EventEmitter{
|
|
|
214
214
|
this.clients.forEach((value, key) => {
|
|
215
215
|
if (key.includes(room_key)) {
|
|
216
216
|
value.forEach(client => {
|
|
217
|
-
if (socket != client || socket == client && data.
|
|
217
|
+
if (socket != client || socket == client && data.broadcastSender != false) {
|
|
218
218
|
if (isAsync) {
|
|
219
219
|
asyncData.push({socket: client, message: responseData})
|
|
220
220
|
} else {
|