mirror of
https://github.com/balena-os/balena-supervisor.git
synced 2025-02-20 17:52:51 +00:00
shorter defaults setting, also allows manual timestamps should someone need them
This commit is contained in:
parent
d47fdf8a3c
commit
433d0bc0f0
@ -28,10 +28,10 @@ publish = do ->
|
||||
if _.isString(message)
|
||||
message = { message }
|
||||
|
||||
message.timestamp = Date.now()
|
||||
|
||||
# Stop pubnub logging loads of "Missing Message" errors, as they are quite distracting
|
||||
message.message or= ' '
|
||||
_.defaults message,
|
||||
timestamp: Date.now()
|
||||
# Stop pubnub logging loads of "Missing Message" errors, as they are quite distracting
|
||||
message: ' '
|
||||
|
||||
pubnub.publish({ channel, message })
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user