Missing query argument in nspMiddleware (#16)

Without this argument it's not possible to use query object with token and other items.
This commit is contained in:
Alexey Topolyanskiy
2020-06-16 14:54:03 -07:00
committed by GitHub
parent fa0465afbb
commit e1494a70db

View File

@@ -67,7 +67,7 @@ export default class SocketIOCollaboration {
if (!this.backend.getDocument(path)) { if (!this.backend.getDocument(path)) {
const doc = onDocumentLoad const doc = onDocumentLoad
? await onDocumentLoad(path) ? await onDocumentLoad(path, query)
: this.options.defaultValue : this.options.defaultValue
if (!doc) return next(null, false) if (!doc) return next(null, false)