- if (!ttValidString($cl_login)) $errors->add($i18n->getKey('error.field'), $i18n->getKey('label.login'));
- if (!ttValidString($cl_password)) $errors->add($i18n->getKey('error.field'), $i18n->getKey('label.password'));
-
- if ($errors->isEmpty()) {
- // Use the "limit" plugin if we have one. Ignore include errors.
+ if (!ttValidString($cl_login)) $err->add($i18n->get('error.field'), $i18n->get('label.login'));
+ if (!ttValidString($cl_password)) $err->add($i18n->get('error.field'), $i18n->get('label.password'));
+
+ if ($err->no()) {
+ // Use the "limit" plugin if we have one. Ignore include errors.