diff --git a/app/Traits/MessagePath.php b/app/Traits/MessagePath.php index cdadef8..946775f 100644 --- a/app/Traits/MessagePath.php +++ b/app/Traits/MessagePath.php @@ -32,8 +32,9 @@ trait MessagePath if ($mo->path->count()) if ($mo instanceof Netmail) { + // Incoming processed message havent converted the path into a collection of addresses yet foreach ($mo->path as $o) - $reply .= sprintf("VIA: %s\r",$mo->via($o)); + $reply .= sprintf("VIA: %s\r",(is_string($o) ? $o : $mo->via($o))); } elseif ($mo instanceof Echomail) { // Rejected echomails dont have a collection of Address::class for paths