Fix AEGIS.agent() lookup
It now considers the address field to be an identity, just like the UUID
field, since most agents are still looked up via their SSH host+port.
return agents;
},
agent: function (uuid) {
- return this.find('agent', { uuid: uuid });
+ for (var uuid in this.data.agent || {}) {
+ var agent = this.data.agent[uuid];
+ if (!agent.hidden && (agent.uuid == uuid || agent.address == uuid)) {
+ return agent;
+ }
+ }
+ return undefined;
},
archives: function (q) {
