Skip to content
This repository
Browse code

MINOR: Removed notice-level errors from form field construction.

  • Loading branch information...
commit 6a08a82c9c83611db5a9e6e361d02fec1d3cb302 1 parent 7c6050b
Sam Minnée authored January 10, 2012
2  forms/DateField.php
@@ -107,7 +107,7 @@ function __construct($name, $title = null, $value = null) {
107 107
 			}
108 108
 		}
109 109
 
110  
-		parent::__construct($name, $title, $value, $form, $rightTitle);
  110
+		parent::__construct($name, $title, $value);
111 111
 	}
112 112
 
113 113
 	function FieldHolder() {
1  forms/FormField.php
@@ -106,7 +106,6 @@ function __construct($name, $title = null, $value = null) {
106 106
 		$this->title = ($title === null) ? $name : $title;
107 107
 
108 108
 		if($value !== NULL) $this->setValue($value);
109  
-		if($form) $this->setForm($form);
110 109
 
111 110
 		parent::__construct();
112 111
 	}
4  tests/forms/TextareaFieldTest.php
@@ -7,7 +7,7 @@ class TextareaFieldTest extends SapphireTest {
7 7
 	 */
8 8
 	function testTextEncoding() {
9 9
 		$inputText = "This is my <text>These are some unicodes: äöü&<>";
10  
-		$field = new TextareaField("Test", "Test", 5, 20);
  10
+		$field = new TextareaField("Test", "Test");
11 11
 		$field->setValue($inputText);
12 12
 		$this->assertContains('This is my &lt;text&gt;These are some unicodes: &auml;&ouml;&uuml;&amp;&lt;&gt;', $field->Field());
13 13
 	}
@@ -17,7 +17,7 @@ function testTextEncoding() {
17 17
 	 */
18 18
 	function testReadonlyTextEncoding() {
19 19
 		$inputText = "This is my <text>These are some unicodes: äöü&<>";
20  
-		$field = new TextareaField("Test", "Test", 5, 20);
  20
+		$field = new TextareaField("Test", "Test");
21 21
 		$field = $field->performReadonlyTransformation();
22 22
 		$field->setValue($inputText);
23 23
 		$this->assertContains('This is my &lt;text&gt;These are some unicodes: &auml;&ouml;&uuml;&amp;&lt;&gt;', $field->Field());

0 notes on commit 6a08a82

Please sign in to comment.
Something went wrong with that request. Please try again.