From cbd393d56b16a30e475b3c01e2b351494c193eee Mon Sep 17 00:00:00 2001 From: muxator Date: Wed, 27 Mar 2019 00:08:11 +0100 Subject: [PATCH] handler/PadMessageHandler.js: handleMessage() got the wrong padId for read only pads This was almost guaranteed to be broken. Found by the Typescript compiler when doing an experimental conversion. --- src/node/handler/PadMessageHandler.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/node/handler/PadMessageHandler.js b/src/node/handler/PadMessageHandler.js index 199c9528b..ffbb74ea8 100644 --- a/src/node/handler/PadMessageHandler.js +++ b/src/node/handler/PadMessageHandler.js @@ -287,7 +287,7 @@ exports.handleMessage = async function(client, message) if (padId.indexOf("r.") === 0) { // Pad is readOnly, first get the real Pad ID - padId = await readOnlyManager.getPadId(padID); + padId = await readOnlyManager.getPadId(padId); } let { accessStatus } = await securityManager.checkAccess(padId, auth.sessionID, auth.token, auth.password);