mirror of
https://github.com/Ylianst/MeshCentral.git
synced 2025-02-15 04:21:51 +00:00
Fixed diagnostic agent 'log', to write log to correct ID
This commit is contained in:
parent
e55386232d
commit
5706d8d4ad
1 changed files with 3 additions and 2 deletions
|
@ -1134,9 +1134,10 @@ module.exports.CreateMeshAgent = function (parent, db, ws, req, args, domain) {
|
|||
}
|
||||
case 'log': {
|
||||
// Only the diagnostic agent can do
|
||||
if (((obj.agentInfo.capabilities & 0x40) != 0) && (typeof command.value.command.value == 'string') && (command.value.command.value.length < 256)) {
|
||||
if (((obj.agentInfo.capabilities & 0x40) != 0) && (typeof command.value.value == 'string') && (command.value.value.length < 256))
|
||||
{
|
||||
// Log a value in the event log of the main again
|
||||
var event = { etype: 'node', action: 'diagnostic', nodeid: obj.dbNodeKey, domain: domain.id, msg: command.value.command.value };
|
||||
var event = { etype: 'node', action: 'diagnostic', nodeid: obj.realNodeKey, domain: domain.id, msg: command.value.value };
|
||||
parent.parent.DispatchEvent(['*', obj.dbMeshKey], obj, event);
|
||||
}
|
||||
break;
|
||||
|
|
Loading…
Reference in a new issue