run keep awake every 30 seconds
This commit is contained in:
parent
83a75def06
commit
f93d10f850
|
@ -9,4 +9,15 @@ export const keepAwake = functions.pubsub
|
|||
callCloudFunction('placeBet'),
|
||||
callCloudFunction('resolveMarket'),
|
||||
])
|
||||
|
||||
await sleep(30)
|
||||
|
||||
await Promise.all([
|
||||
callCloudFunction('placeBet'),
|
||||
callCloudFunction('resolveMarket'),
|
||||
])
|
||||
})
|
||||
|
||||
const sleep = (seconds: number) => {
|
||||
return new Promise((resolve) => setTimeout(resolve, seconds * 1000))
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue
Block a user