优化 RedisConnection,采用单例模式导出
This commit is contained in:
@@ -39,5 +39,6 @@ class RedisConnection {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
const redisConnection = new RedisConnection();
|
const _redisConnection = new RedisConnection();
|
||||||
export default redisConnection.getPool();
|
const redisConnection = _redisConnection.getPool();
|
||||||
|
export default redisConnection;
|
||||||
Reference in New Issue
Block a user