From 63d8037189b5e21a85db3855e04c99b2e47ef3a8 Mon Sep 17 00:00:00 2001 From: Kevin Montag Date: Fri, 1 Nov 2019 15:57:52 +0100 Subject: [PATCH] Replace table.getn with length operator --- redlock.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/redlock.js b/redlock.js index b8e620f..9867631 100644 --- a/redlock.js +++ b/redlock.js @@ -20,7 +20,7 @@ const lockScript = ` end -- Return the number of entries added. - return table.getn(KEYS) + return #KEYS `; const unlockScript = ` @@ -51,7 +51,7 @@ const extendScript = ` end -- Return the number of entries updated. - return table.getn(KEYS) + return #KEYS `; // defaults