YUKI Hiroshi
null+****@clear*****
Mon Dec 16 17:04:24 JST 2013
YUKI Hiroshi 2013-12-16 17:04:24 +0900 (Mon, 16 Dec 2013) New Revision: 0d51a910cafc22ec41dba03399e186c8b0dc6c8a https://github.com/droonga/express-droonga/commit/0d51a910cafc22ec41dba03399e186c8b0dc6c8a Message: Raise error for unexpected method call Modified files: lib/droonga-protocol/connection.js Modified: lib/droonga-protocol/connection.js (+3 -0) =================================================================== --- lib/droonga-protocol/connection.js 2013-12-16 17:00:13 +0900 (f944467) +++ lib/droonga-protocol/connection.js 2013-12-16 17:04:24 +0900 (3975b84) @@ -131,6 +131,9 @@ function toPositiveInteger(number) { } Connection.prototype.emitMessage = function(type, body, callback, options) { + if (!this._sender) + throw new Error('emitMessage is unexpectedly called after the connection is closed!'); + options = options || {}; // support emitMessage(type, body, options) -------------- next part -------------- HTML����������������������������... Download