We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 2463499 commit 6e168f8Copy full SHA for 6e168f8
1 file changed
src/service.js
@@ -737,6 +737,15 @@ module.exports = function (mixinOptions) {
737
this.dataLoaderOptions = new Map();
738
this.dataLoaderBatchParams = new Map();
739
740
+ // Bind service to onConnect method
741
+ if (
742
+ mixinOptions.serverOptions.subscriptions &&
743
+ _.isFunction(mixinOptions.serverOptions.subscriptions.onConnect)
744
+ ) {
745
+ mixinOptions.serverOptions.subscriptions.onConnect =
746
+ mixinOptions.serverOptions.subscriptions.onConnect.bind(this);
747
+ }
748
+
749
const route = _.defaultsDeep(mixinOptions.routeOptions, {
750
aliases: {
751
async "/"(req, res) {
0 commit comments