@@ -105,7 +105,7 @@ public function init(): void
105105 $ this ->mail_priority = symfony_email::PRIORITY_NORMAL ;
106106
107107 $ this ->additional_headers = [];
108- $ this ->use_queue = true ;
108+ $ this ->set_use_queue () ;
109109 unset($ this ->template , $ this ->reply_to , $ this ->from );
110110 }
111111
@@ -242,10 +242,10 @@ public function subject(string $subject = ''): void
242242 */
243243 public function anti_abuse_headers (\phpbb \config \config $ config , \phpbb \user $ user ): void
244244 {
245- $ this ->headers -> addHeader ('X-AntiAbuse ' , 'Board servername - ' . $ config ['server_name ' ]);
246- $ this ->headers -> addHeader ('X-AntiAbuse ' , 'User_id - ' . $ user ->data ['user_id ' ]);
247- $ this ->headers -> addHeader ('X-AntiAbuse ' , 'Username - ' . $ user ->data ['username ' ]);
248- $ this ->headers -> addHeader ('X-AntiAbuse ' , 'User IP - ' . $ user ->ip );
245+ $ this ->header ('X-AntiAbuse ' , 'Board servername - ' . $ config ['server_name ' ]);
246+ $ this ->header ('X-AntiAbuse ' , 'User_id - ' . $ user ->data ['user_id ' ]);
247+ $ this ->header ('X-AntiAbuse ' , 'Username - ' . $ user ->data ['username ' ]);
248+ $ this ->header ('X-AntiAbuse ' , 'User IP - ' . $ user ->ip );
249249 }
250250
251251 /**
@@ -313,7 +313,7 @@ protected function build_headers(): void
313313
314314 foreach ($ headers as $ header => $ value )
315315 {
316- $ this ->headers -> addHeader ($ header , $ value );
316+ $ this ->header ($ header , $ value );
317317 }
318318
319319 }
@@ -576,4 +576,12 @@ public function send(): bool
576576
577577 return true ;
578578 }
579+
580+ /**
581+ * {@inheritdoc}
582+ */
583+ public function header (string $ header_name , mixed $ header_value ): void
584+ {
585+ $ this ->headers ->addHeader ($ header_name , $ header_value );
586+ }
579587}
0 commit comments