From 197d03f9d9917eacba5e80aa2f0d9bf1dc535261 Mon Sep 17 00:00:00 2001 From: atm-lena Date: Thu, 3 Sep 2020 09:23:10 +0200 Subject: [PATCH] FIX selectModelMail() : if default and no mail models select default model --- htdocs/core/class/html.form.class.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/htdocs/core/class/html.form.class.php b/htdocs/core/class/html.form.class.php index a913a878251..3daaf572ca6 100644 --- a/htdocs/core/class/html.form.class.php +++ b/htdocs/core/class/html.form.class.php @@ -7992,8 +7992,8 @@ class Form $formmail = new FormMail($db); $result = $formmail->fetchAllEMailTemplate($modelType, $user, $langs); + if ($default) $TModels[0] = $langs->trans('DefaultMailModel'); if ($result > 0) { - if ($default) $TModels[0] = $langs->trans('DefaultMailModel'); foreach ($formmail->lines_model as $model){ $TModels[$model->id] = $model->label; }