Set packed boolean when packing Netmail's is successful

This commit is contained in:
Deon George
2021-08-16 22:30:34 +10:00
parent 628293c741
commit 5bf612e5b4
3 changed files with 10 additions and 5 deletions

View File

@@ -107,6 +107,8 @@ class Message extends FTNBase
private Collection $via; // The path the message has gone using Via lines (Netmail)
private Collection $unknown; // Temporarily hold attributes we have no logic for.
public bool $packed = FALSE; // Has the message been packed successfully
// Convert characters into printable chars
// https://int10h.org/oldschool-pc-fonts/readme/#437_charset
private const CP437 = [
@@ -157,6 +159,7 @@ class Message extends FTNBase
{
$this->domain = $domain;
$this->header = [];
$this->kludge = collect();
$this->msgid = '';
@@ -392,9 +395,7 @@ class Message extends FTNBase
*/
public function __toString(): string
{
$return = '';
$return .= pack(collect(self::header)->pluck(1)->join(''),
$return = pack(collect(self::header)->pluck(1)->join(''),
$this->ff,
$this->tf,
$this->fn,