更新 target/redis/pool.lua
This commit is contained in:
@@ -7,9 +7,13 @@ redis_pool.__index = redis_pool
|
|||||||
创建一个新的 fw_redis_pool 对象
|
创建一个新的 fw_redis_pool 对象
|
||||||
@return 返回一个新的 fw_redis_pool 对象
|
@return 返回一个新的 fw_redis_pool 对象
|
||||||
]]
|
]]
|
||||||
function redis_pool.new()
|
function redis_pool.new(pool)
|
||||||
local instance = setmetatable({}, redis_pool)
|
local instance = setmetatable({}, redis_pool)
|
||||||
instance.module = fw_redis_pool.new()
|
if pool == nil then
|
||||||
|
instance.module = fw_redis_pool.new()
|
||||||
|
else
|
||||||
|
instance.module = pool
|
||||||
|
end
|
||||||
return instance
|
return instance
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user