More complete rework of packet parsing and packet generation with 29710c
This commit is contained in:
@@ -4,9 +4,8 @@ namespace App\Notifications\Netmails;
|
||||
|
||||
use Illuminate\Support\Facades\Log;
|
||||
|
||||
use App\Classes\FTN\Message;
|
||||
use App\Notifications\Netmails;
|
||||
use App\Models\{Address,Netmail,System};
|
||||
use App\Models\{Address,Netmail};
|
||||
use App\Traits\{MessagePath,PageTemplate};
|
||||
|
||||
class NetmailForward extends Netmails
|
||||
@@ -16,15 +15,15 @@ class NetmailForward extends Netmails
|
||||
private const LOGKEY = 'NNP';
|
||||
|
||||
private Address $ao;
|
||||
private Message $mo;
|
||||
private Netmail $mo;
|
||||
|
||||
/**
|
||||
* Reply to a netmail ping request.
|
||||
*
|
||||
* @param Message $mo
|
||||
* @param Netmail $mo
|
||||
* @param Address $ao
|
||||
*/
|
||||
public function __construct(Message $mo,Address $ao)
|
||||
public function __construct(Netmail $mo,Address $ao)
|
||||
{
|
||||
parent::__construct();
|
||||
|
||||
@@ -44,9 +43,9 @@ class NetmailForward extends Netmails
|
||||
$o = $this->setupNetmail($notifiable);
|
||||
$ao = $notifiable->routeNotificationFor(static::via);
|
||||
|
||||
Log::info(sprintf('%s:+ Advising [%s@%s] that netmail to [%s] will be forwarded to [%s].',self::LOGKEY,$this->mo->user_from,$ao->ftn,$this->mo->user_to,$this->ao->ftn));
|
||||
Log::info(sprintf('%s:+ Advising [%s@%s] that netmail to [%s] will be forwarded to [%s].',self::LOGKEY,$this->mo->from,$ao->ftn,$this->mo->to,$this->ao->ftn));
|
||||
|
||||
$o->to = $this->mo->user_from;
|
||||
$o->to = $this->mo->from;
|
||||
$o->replyid = $this->mo->msgid;
|
||||
$o->subject = sprintf('Your netmail is being forwarded to %s',$this->ao->ftn3d);
|
||||
|
||||
@@ -56,10 +55,10 @@ class NetmailForward extends Netmails
|
||||
$msg->addText("Howdy, Clrghouz is not a BBS, so users cannot login to collect netmail.\r\r\r");
|
||||
$msg->addText(sprintf("Never fear, your msg [%s] to [%s] has been forwarded, to [%s].\r\r",
|
||||
$this->mo->msgid,
|
||||
$this->mo->user_to,
|
||||
$this->mo->to,
|
||||
$this->ao->ftn3d,
|
||||
));
|
||||
$msg->addText(sprintf("To avoid receiving this netmail, send messages to [%s] to [%s].\r\r",$this->mo->user_to,$this->ao->ftn3d));
|
||||
$msg->addText(sprintf("To avoid receiving this netmail, send messages to [%s] to [%s].\r\r",$this->mo->to,$this->ao->ftn3d));
|
||||
|
||||
$o->msg = $msg->render();
|
||||
$o->tagline = 'Thank you so much for your mail. I love it already.';
|
||||
|
Reference in New Issue
Block a user