diff --git a/htdocs/core/class/html.form.class.php b/htdocs/core/class/html.form.class.php
index 0d400274557..5bf6cec8192 100644
--- a/htdocs/core/class/html.form.class.php
+++ b/htdocs/core/class/html.form.class.php
@@ -6713,7 +6713,7 @@ class Form
}
}
// If reset_scripts is not empty, print the link with the reset_scripts in the onClick
- if ($reset_scripts && empty($conf->dol_optimize_smallscreen)) {
+ if ($reset_scripts && empty($conf->global->MAIN_OPTIMIZEFORTEXTBROWSER)) {
$retstring .= ' ';