From 3a35bce9e7aaed04c0a7a61a1e76e7ac9c5b1dda Mon Sep 17 00:00:00 2001 From: Deon George Date: Tue, 19 Sep 2023 10:21:17 +1000 Subject: [PATCH] Changing System::match() to not include NC, some debugging updates --- app/Classes/FTN/Packet.php | 6 +++--- app/Classes/File/Receive.php | 2 +- app/Models/System.php | 2 +- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/app/Classes/FTN/Packet.php b/app/Classes/FTN/Packet.php index 276dda3..d8499b7 100644 --- a/app/Classes/FTN/Packet.php +++ b/app/Classes/FTN/Packet.php @@ -415,7 +415,7 @@ class Packet extends FTNBase implements \Iterator, \Countable */ private function parseMessage(string $message): void { - Log::info(sprintf('%s:Processing message [%d] bytes',self::LOGKEY,strlen($message))); + Log::info(sprintf('%s:+ Processing message [%d] bytes',self::LOGKEY,strlen($message))); $msg = Message::parseMessage($message,$this->zone); @@ -456,7 +456,7 @@ class Packet extends FTNBase implements \Iterator, \Countable $so->addresses()->save($ao); - Log::alert(sprintf('%s: - To FTN is not defined, creating new entry for [%s] (%d)',self::LOGKEY,$msg->tboss,$ao->id)); + Log::alert(sprintf('%s:- To FTN is not defined, creating new entry for [%s] (%d)',self::LOGKEY,$msg->tboss,$ao->id)); } if ($msg->errors->messages()->has('from') && $msg->tzone) { @@ -491,7 +491,7 @@ class Packet extends FTNBase implements \Iterator, \Countable $so->addresses()->save($ao); - Log::alert(sprintf('%s: - From FTN is not defined, creating new entry for [%s] (%d)',self::LOGKEY,$msg->fboss,$ao->id)); + Log::alert(sprintf('%s:- From FTN is not defined, creating new entry for [%s] (%d)',self::LOGKEY,$msg->fboss,$ao->id)); } if ($msg->errors->messages()->has('user_from') || $msg->errors->messages()->has('user_to')) { diff --git a/app/Classes/File/Receive.php b/app/Classes/File/Receive.php index bb2fa7b..5f12a9b 100644 --- a/app/Classes/File/Receive.php +++ b/app/Classes/File/Receive.php @@ -114,7 +114,7 @@ class Receive extends Base fclose($this->f); // Set our mtime - Log::info(sprintf('%s:= Setting file [%s] to time [%s]',self::LOGKEY,$this->receiving->full_name,$this->receiving->recvmtime)); + Log::debug(sprintf('%s:= Setting file [%s] to time [%s]',self::LOGKEY,$this->receiving->full_name,$this->receiving->recvmtime)); touch($this->receiving->full_name,$this->receiving->recvmtime); $this->f = NULL; diff --git a/app/Models/System.php b/app/Models/System.php index e1a85c4..6dbd4ad 100644 --- a/app/Models/System.php +++ b/app/Models/System.php @@ -211,7 +211,7 @@ class System extends Model * @return Collection * @todo This doesnt return sorted addresses, so it is possible that a node address is returned first, before a NC/HC, etc */ - public function match(Zone $o,int $type=(Address::NODE_NC|Address::NODE_HC|Address::NODE_ACTIVE|Address::NODE_PVT|Address::NODE_POINT)): Collection + public function match(Zone $o,int $type=(Address::NODE_HC|Address::NODE_ACTIVE|Address::NODE_PVT|Address::NODE_POINT)): Collection { return $this->akas ->where(function($item) use($o) {