Close #1086. Add User-Agent to Google Analytics
This commit is contained in:
parent
fd1a5cba50
commit
4ba714940d
|
@ -218,7 +218,11 @@ module.exports = class Beautifiers extends EventEmitter
|
|||
atom.config.set "atom-beautify.general._analyticsUserId", uuid.v4()
|
||||
# Setup Analytics User Id
|
||||
userId = atom.config.get("atom-beautify.general._analyticsUserId")
|
||||
@analytics ?= new ua(trackingId, userId)
|
||||
@analytics ?= new ua(trackingId, userId, {
|
||||
headers: {
|
||||
"User-Agent": navigator.userAgent
|
||||
}
|
||||
})
|
||||
@analytics[type](payload).send()
|
||||
catch error
|
||||
logger.error(error)
|
||||
|
|
Loading…
Reference in New Issue