How can I make SMTP plugin work with multiple languages? I'm using the SMTP Authentication Support plugin for mail from my Drupal 8 server. 

Sending mail from a webform works fine as long as the visitor is using the default language, which is English. It does not send when using any other language.

The message in the error log is not helpful:


  Error sending e-mail from email@site.com to email@site.com: SMTP Error: Could not connect to SMTP host.


This makes no sense to me. How can it not be connecting, when the same connection information is ok on English?

How can I resolve this? Here's what I've tried to do:


I've asked for support on SMTP's issues page, but have not received any response yet.
Set the language detection up two different ways: by domain or by URL. Same result on both.
Tried two different SMTP servers, with the same result on both.
Tried SSL and standard protocols for SMTP.
The problem is that the parameters are not translatable. In my case it has been solved by overriding the values of the port and protocol variables in settings.php.

$config['smtp.settings']['smtp_port'] = '587';
$config['smtp.settings']['smtp_protocol'] = 'tls';