fix build problems

This commit is contained in:
Brian Gough 2019-07-09 12:20:59 +01:00
parent 580b100362
commit dd54789e2b
2 changed files with 5 additions and 5 deletions

View file

@ -1,7 +1,7 @@
redis = require("redis-sharelatex")
modules.export = RedisClientManager =
createClientList: (configs...)
module.exports = RedisClientManager =
createClientList: (configs...) ->
# create a dynamic list of redis clients, excluding any configurations which are not defined
clientList = (redis.createClient(x) for x in configs when x?))
clientList = (redis.createClient(x) for x in configs when x?)
return clientList

View file

@ -7,8 +7,8 @@ describe "WebsocketLoadBalancer", ->
beforeEach ->
@rclient = {}
@WebsocketLoadBalancer = SandboxedModule.require modulePath, requires:
"redis-sharelatex":
createClient: () => @rclient
"./RedisClientManager":
createClientList: () => []
"logger-sharelatex": @logger = { log: sinon.stub(), error: sinon.stub() }
"./SafeJsonParse": @SafeJsonParse =
parse: (data, cb) => cb null, JSON.parse(data)