The problem here is that $object for SYS_IF_DOWN points to node object, not interface object. Correct script will look like this:
Best regards,
Victor
Code Select
iface = $node->getInterface($event->parameters[5]);
return iface != null and iface->peerNode == null;
Best regards,
Victor