Browse Source

Fix name of varible

mehdi fathi 8 years ago
parent
commit
d6c09e3157
2 changed files with 8 additions and 2 deletions
  1. 2 2
      src/View/Form/FormContext.php
  2. 6 0
      tests/TestCase/View/Form/FormContextTest.php

+ 2 - 2
src/View/Form/FormContext.php

@@ -135,9 +135,9 @@ class FormContext implements ContextInterface
     public function attributes($field)
     {
         $column = (array)$this->_form->schema()->field($field);
-        $whitelist = ['length' => null, 'precision' => null];
+        $whiteList = ['length' => null, 'precision' => null];
 
-        return array_intersect_key($column, $whitelist);
+        return array_intersect_key($column, $whiteList);
     }
 
     /**

+ 6 - 0
tests/TestCase/View/Form/FormContextTest.php

@@ -25,6 +25,12 @@ use Cake\View\Form\FormContext;
  */
 class FormContextTest extends TestCase
 {
+    /**
+     * The request object.
+     *
+     * @var \Cake\Http\ServerRequest
+     */
+    protected $request;
 
     /**
      * setup method.