From df548739dad678bebcd8aadd437ebac30978cba7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=96=9F=E9=85=8C=20=E9=B5=AC=E5=85=84?= Date: Wed, 6 Apr 2022 13:51:37 +0900 Subject: [PATCH] Upgraded redis client but use legacy mode --- redisclient.js | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/redisclient.js b/redisclient.js index 11bce39..3781668 100644 --- a/redisclient.js +++ b/redisclient.js @@ -5,11 +5,10 @@ const Redis = require( "redis" ); const SessConf = cl.load( "config.all" ).sx.modular.session; -var Client = Redis.createClient( - SessConf.config.port - , SessConf.config.host - , SessConf.config.options -); +var Client = Redis.createClient({ + "legacyMode": true + , "url": `redis://${SessConf.config.host}:${SessConf.config.port}/${SessConf.config.database}` +}); Client.addListener( "error", ( e ) => { throw e; } );