Better log message

This commit is contained in:
Douglas Barone 2020-12-17 13:04:06 -04:00
parent 738bae1a15
commit cf21f1534d

View File

@ -17,13 +17,15 @@ cron.schedule('*/1 * * * *', async () => {
const devices = await updateDevicesInfo() const devices = await updateDevicesInfo()
logMsg(`updateDevicesInfo updated ${devices} devices.`)
let mappings = 0 let mappings = 0
if (devices > 0) mappings = await updateUserIdMappings() if (devices > 0) {
logMsg('updateUserIdMappings started.')
logMsg( mappings = await updateUserIdMappings()
`updateDevicesInfo updated ${devices} devices and ${mappings} user-id mappings.` logMsg(`updateUserIdMappings updated ${mappings} user-id mappings.`)
) }
}) })
cron.schedule( cron.schedule(