Warning 'to_name' undefined with plugin mailer_smtp

Hi,

every time I send a mail with the plugin mailer_smtp a warning is written in the event log:

I’m using the dynamic docker install on a RaspberryPi and the latest commit v21.03-de47082ca.

Can I define the ‘to_name’ in the configuration or is this a bug?

it’s your name, set it in preferences.

The only thing I see is:

Config::SMTP_FROM_NAME => [ “Tiny Tiny RSS”, Config::T_STRING ],

but no ‘to_name’ - or do I miss something?

My name in the preferences is already set

I was looking at this a couple days ago. Follow the error message to the file ./classes/mailer.php

Mail is being sent out using this variable when sharing an article:
$to_combined = $to_name ? “$to_name <$to_address>” : $to_address;

The $to_name will be undefined when sending a message to: [email protected] …However, an address formatted like this: John Smith <[email protected]> should go out without an error.

I didn’t want to be bothered with adding a name so I updated the line: $to_name = $params[“to_name”] ?? “”;

The test email in preferences does not seem to care if the to name is missing.

yeah name should just do that by default, it’s not like it’s a required thing.

I also had a look at mailer.php but an email like this John Smith <[email protected]> doesn’t work. The error ‘You must at leat provide one recipient email address’ is displayed.
It is not a required thing but maybe I just update the line like @jklm proposed