mirror of
https://github.com/zerotier/ZeroTierOne.git
synced 2025-06-07 13:03:45 +02:00
Add lastSeen and identity to member record if not present.
This commit is contained in:
parent
914bebba31
commit
49247180dc
1 changed files with 4 additions and 0 deletions
|
@ -310,6 +310,10 @@ function doNetconfRequest(message)
|
||||||
'lastSeen': Date.now(),
|
'lastSeen': Date.now(),
|
||||||
'authorized': authorized ? '1' : '0' // reset authorized to unhide in UI, since UI uses -1 to hide
|
'authorized': authorized ? '1' : '0' // reset authorized to unhide in UI, since UI uses -1 to hide
|
||||||
};
|
};
|
||||||
|
if (!('identity' in member))
|
||||||
|
updatedFields['identity'] = peerId.toString();
|
||||||
|
if (!('firstSeen' in member))
|
||||||
|
updatedFields['firstSeen'] = Date.now();
|
||||||
if (message.data['from'])
|
if (message.data['from'])
|
||||||
updatedFields['lastAt'] = message.data['from'];
|
updatedFields['lastAt'] = message.data['from'];
|
||||||
if (message.data['clientVersion'])
|
if (message.data['clientVersion'])
|
||||||
|
|
Loading…
Add table
Reference in a new issue