@jcbuisson/express-x 1.7.8 → 1.7.10
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 +1 -1
- package/src/server.mjs +3 -3
package/package.json
CHANGED
package/src/server.mjs
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
|
|
2
|
-
import
|
|
2
|
+
import http from 'http'
|
|
3
3
|
import { Server } from 'socket.io'
|
|
4
4
|
import express from 'express'
|
|
5
5
|
|
|
@@ -125,7 +125,7 @@ export function expressX(prisma, config) {
|
|
|
125
125
|
|
|
126
126
|
// publish event (websocket transport)
|
|
127
127
|
if (config.WS_TRANSPORT && service.publishFunction) {
|
|
128
|
-
const channelNames = await service.publishFunction(result,
|
|
128
|
+
const channelNames = await service.publishFunction(result, methodName)
|
|
129
129
|
app.log('verbose', `publish channels ${service.name} ${methodName} ${channelNames}`)
|
|
130
130
|
const connections = await app.prisma.Connection.findMany({})
|
|
131
131
|
for (const channelName of channelNames) {
|
|
@@ -313,7 +313,7 @@ export function expressX(prisma, config) {
|
|
|
313
313
|
/*
|
|
314
314
|
* Create HTTP server
|
|
315
315
|
*/
|
|
316
|
-
const httpServer =
|
|
316
|
+
const httpServer = new http.Server(app)
|
|
317
317
|
|
|
318
318
|
if (config.WS_TRANSPORT) {
|
|
319
319
|
/*
|