From c4ab64e0fc329e51e586a684cfa5cd34582fc254 Mon Sep 17 00:00:00 2001
From: Jared Hancock <jared@osticket.com>
Date: Tue, 26 Nov 2013 18:18:00 -0600
Subject: [PATCH] oops: Fix lints tests and variable replacement

---
 include/class.user.php                  | 2 +-
 include/i18n/en_US/help/tips/forms.yaml | 2 +-
 setup/test/tests/stubs.php              | 1 +
 3 files changed, 3 insertions(+), 2 deletions(-)

diff --git a/include/class.user.php b/include/class.user.php
index 15f35223c..2d837dad0 100644
--- a/include/class.user.php
+++ b/include/class.user.php
@@ -192,7 +192,7 @@ class User extends UserModel {
             if (!$cd->isValid())
                 $valid = false;
             if ($cd->get('type') == 'U'
-                        && ($form= $cd->getForm($data))
+                        && ($form= $cd->getForm($vars))
                         && ($f=$form->getField('email'))
                         && $f->getClean()
                         && ($u=User::lookup(array('emails__address'=>$f->getClean())))
diff --git a/include/i18n/en_US/help/tips/forms.yaml b/include/i18n/en_US/help/tips/forms.yaml
index 8ce3b89a5..e9af02177 100644
--- a/include/i18n/en_US/help/tips/forms.yaml
+++ b/include/i18n/en_US/help/tips/forms.yaml
@@ -73,7 +73,7 @@ field_variable:
         <strong>variable</strong> is the name used in this column.<br>
         <br>
         <em>Company information is available via
-        <code>%{company.variable}</code> and user information is available
+        <code>%{</code><code>company.variable}</code> and user information is available
         via <code>%{ticket.user.variable}</code></em>
 
 field_delete:
diff --git a/setup/test/tests/stubs.php b/setup/test/tests/stubs.php
index 5a78251f3..591700ec5 100644
--- a/setup/test/tests/stubs.php
+++ b/setup/test/tests/stubs.php
@@ -9,6 +9,7 @@ class mysqli {
     function ssl_set() {}
     function real_connect() {}
     function select_db() {}
+    function set_charset() {}
 }
 
 class mysqli_stmt {
-- 
GitLab