From c4a749c2e54388dcf8efd40b6c90975f28439f4d Mon Sep 17 00:00:00 2001 From: Prateek Jain Date: Thu, 30 Apr 2020 23:39:17 +0530 Subject: [PATCH] [FIX] Send totp-code to meteor call (#2050) * fixed-issue * removed-variable-name-errors * reverted-last-commit Co-authored-by: Diego Mello --- app/lib/rocketchat.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/lib/rocketchat.js b/app/lib/rocketchat.js index 52e8f623..5333f28e 100644 --- a/app/lib/rocketchat.js +++ b/app/lib/rocketchat.js @@ -909,7 +909,7 @@ const RocketChat = { methodCall(...args) { return new Promise(async(resolve, reject) => { try { - const result = await this.sdk.methodCall(...args, this.code); + const result = await this.sdk.methodCall(...args, this.code || ''); return resolve(result); } catch (e) { if (e.error && (e.error === 'totp-required' || e.error === 'totp-invalid')) {