fixed multiple outgoing/incoming links bug