summaryrefslogtreecommitdiff
path: root/lib/ot/editor-socketio-server.js
diff options
context:
space:
mode:
authorWu Cheng-Han2015-07-16 22:46:06 +0800
committerWu Cheng-Han2015-07-16 22:46:06 +0800
commitd14c5bdc9cabf632262067466ef02374cee496cd (patch)
tree63baaaa8c0205f55cb30f7e353e0727f14543851 /lib/ot/editor-socketio-server.js
parent57253d28a7ad2037ba4d5da69d69f653e651c49b (diff)
Added document max length limit, enforceMaxLength on change and show modal when reach the limit.
Diffstat (limited to 'lib/ot/editor-socketio-server.js')
-rwxr-xr-xlib/ot/editor-socketio-server.js1
1 files changed, 1 insertions, 0 deletions
diff --git a/lib/ot/editor-socketio-server.js b/lib/ot/editor-socketio-server.js
index ade8fc52..67920cbf 100755
--- a/lib/ot/editor-socketio-server.js
+++ b/lib/ot/editor-socketio-server.js
@@ -95,6 +95,7 @@ EditorSocketIOServer.prototype.onOperation = function (socket, revision, operati
try {
var clientId = socket.id;
var wrappedPrime = this.receiveOperation(revision, wrapped);
+ if(!wrappedPrime) return;
//console.log("new operation: " + JSON.stringify(wrapped));
this.getClient(clientId).selection = wrappedPrime.meta;
revision = this.operations.length;