Completed
Push — master ( a0fa0b...06252b )
by Tom
02:58
created
src/Formatter/Date.php 2 patches
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -11,7 +11,7 @@  discard block
 block discarded – undo
11 11
 	/** Converts $val into a \DateTime object if it's not already */
12 12
 	private function getDate($val) {
13 13
 		$tz = new \DateTimeZone($this->locale['timezone']);
14
-		$date =  $val instanceof \DateTime ? $val : new \DateTime($val, $tz);
14
+		$date = $val instanceof \DateTime ? $val : new \DateTime($val, $tz);
15 15
 		$date->setTimeZone($tz);
16 16
 		return $date;
17 17
 	}
@@ -30,7 +30,7 @@  discard block
 block discarded – undo
30 30
 
31 31
 	/** Formats \DateTime as Date and Time using formats from $locale */
32 32
 	public function dateTime($val) {
33
-		return $this->date($val, $this->locale['date_format'] . ' ' . $this->locale['time_format']);
33
+		return $this->date($val, $this->locale['date_format'].' '.$this->locale['time_format']);
34 34
 	}
35 35
 
36 36
 	/** Generates relative time offsets based on system clock. e.g "10 minutes ago" or "In 6 months"
@@ -42,7 +42,7 @@  discard block
 block discarded – undo
42 42
 		$diff = $now->diff($date);
43 43
 
44 44
 
45
-		$diffDays = $diff->invert === 1 ? $diff->days : 0- $diff->days;
45
+		$diffDays = $diff->invert === 1 ? $diff->days : 0-$diff->days;
46 46
 
47 47
 		if ($diffDays !== 0) return $this->dayOffset($diffDays);
48 48
 		else return $this->timeOffset($diff);
@@ -68,7 +68,7 @@  discard block
 block discarded – undo
68 68
 
69 69
 	/** Gets date ranges to represent uses of weeks/months/days/etc */
70 70
 	private function getRanges($strings) {
71
-		$ranges =  [
71
+		$ranges = [
72 72
 			[1, 1, $strings['yesterday'], 1, ''],
73 73
 			[1, 13, $strings['past'], 1, 'days'],
74 74
 			[13, 28, $strings['past'], 7, 'weeks'],
@@ -87,7 +87,7 @@  discard block
 block discarded – undo
87 87
 
88 88
 	/** Converts "week" to "weeks", "month" to "months" etc when plural is required using language from $locale */
89 89
 	private function getPlural($strings, $num, $interval) {
90
-		if ($interval !== '') return $num == 1 ? $strings[$interval . '_singular'] : $strings[$interval . '_plural'];
90
+		if ($interval !== '') return $num == 1 ? $strings[$interval.'_singular'] : $strings[$interval.'_plural'];
91 91
 		else return '';
92 92
 	}
93 93
 
Please login to merge, or discard this patch.
Braces   +16 added lines, -6 removed lines patch added patch discarded remove patch
@@ -44,8 +44,11 @@  discard block
 block discarded – undo
44 44
 
45 45
 		$diffDays = $diff->invert === 1 ? $diff->days : 0- $diff->days;
46 46
 
47
-		if ($diffDays !== 0) return $this->dayOffset($diffDays);
48
-		else return $this->timeOffset($diff);
47
+		if ($diffDays !== 0) {
48
+			return $this->dayOffset($diffDays);
49
+		} else {
50
+			return $this->timeOffset($diff);
51
+		}
49 52
 	}
50 53
 
51 54
 	/** Calculates offset in hours/minutes/seconds */
@@ -80,15 +83,22 @@  discard block
 block discarded – undo
80 83
 			[-365, -28, $strings['future'], 28, 'months'],
81 84
 			[-999999, -365, $strings['future'], 365, 'years'],
82 85
 		];
83
-		if (isset($strings['day_before_yesterday'])) array_unshift($ranges, [2, 2, $strings['day_before_yesterday'], 1, '']);
84
-		if (isset($strings['day_after_tomorrow'])) array_unshift($ranges, [-2, -2, $strings['day_after_tomorrow'], 1, '']);
86
+		if (isset($strings['day_before_yesterday'])) {
87
+			array_unshift($ranges, [2, 2, $strings['day_before_yesterday'], 1, '']);
88
+		}
89
+		if (isset($strings['day_after_tomorrow'])) {
90
+			array_unshift($ranges, [-2, -2, $strings['day_after_tomorrow'], 1, '']);
91
+		}
85 92
 		return $ranges;
86 93
 	}
87 94
 
88 95
 	/** Converts "week" to "weeks", "month" to "months" etc when plural is required using language from $locale */
89 96
 	private function getPlural($strings, $num, $interval) {
90
-		if ($interval !== '') return $num == 1 ? $strings[$interval . '_singular'] : $strings[$interval . '_plural'];
91
-		else return '';
97
+		if ($interval !== '') {
98
+			return $num == 1 ? $strings[$interval . '_singular'] : $strings[$interval . '_plural'];
99
+		} else {
100
+			return '';
101
+		}
92 102
 	}
93 103
 
94 104
 	/** Calculates offset in days/weeks/month/years */
Please login to merge, or discard this patch.
src/Formatter/Number.php 2 patches
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -13,7 +13,7 @@
 block discarded – undo
13 13
 
14 14
 	public function currency($num) {
15 15
 		$num = $this->decimal($num, $this->locale['currency_decimals']);
16
-		if ($this->locale['currency_position'] === 'before') return $this->locale['currency'] . $num;
17
-		else return $num . $this->locale['currency'];
16
+		if ($this->locale['currency_position'] === 'before') return $this->locale['currency'].$num;
17
+		else return $num.$this->locale['currency'];
18 18
 	}
19 19
 }
20 20
\ No newline at end of file
Please login to merge, or discard this patch.
Braces   +5 added lines, -2 removed lines patch added patch discarded remove patch
@@ -13,7 +13,10 @@
 block discarded – undo
13 13
 
14 14
 	public function currency($num) {
15 15
 		$num = $this->decimal($num, $this->locale['currency_decimals']);
16
-		if ($this->locale['currency_position'] === 'before') return $this->locale['currency'] . $num;
17
-		else return $num . $this->locale['currency'];
16
+		if ($this->locale['currency_position'] === 'before') {
17
+			return $this->locale['currency'] . $num;
18
+		} else {
19
+			return $num . $this->locale['currency'];
20
+		}
18 21
 	}
19 22
 }
20 23
\ No newline at end of file
Please login to merge, or discard this patch.
src/Hook/DataFunction.php 3 patches
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -75,7 +75,7 @@
 block discarded – undo
75 75
 	}
76 76
 
77 77
 	public function template($val, $element) {
78
-		$newTemplate = new \Transphporm\Builder($this->baseDir . $val[0]);
78
+		$newTemplate = new \Transphporm\Builder($this->baseDir.$val[0]);
79 79
 		$newTemplate->setLocale($this->locale);
80 80
 
81 81
 		$doc = $newTemplate->output([], true)->body;
Please login to merge, or discard this patch.
Doc Comments   +3 added lines patch added patch discarded remove patch
@@ -12,6 +12,9 @@
 block discarded – undo
12 12
 	private $locale;
13 13
 	private $baseDir;
14 14
 	
15
+	/**
16
+	 * @param string $baseDir
17
+	 */
15 18
 	public function __construct(\SplObjectStorage $objectStorage, $data, $locale, $baseDir) {
16 19
 		$this->dataStorage = $objectStorage;
17 20
 		$this->data = $data;
Please login to merge, or discard this patch.
Braces   +25 added lines, -9 removed lines patch added patch discarded remove patch
@@ -22,7 +22,9 @@  discard block
 block discarded – undo
22 22
 	/** Binds data to an element */
23 23
 	public function bind(\DomElement $element, $data, $type = 'data') {
24 24
 		//This is a bit of a hack to workaround #24, might need a better way of doing this if it causes a problem
25
-		if (is_array($data) && $this->isObjectArray($data)) $data = $data[0];
25
+		if (is_array($data) && $this->isObjectArray($data)) {
26
+			$data = $data[0];
27
+		}
26 28
 		$content = isset($this->dataStorage[$element]) ? $this->dataStorage[$element] : [];
27 29
 		$content[$type] = $data;
28 30
 		$this->dataStorage[$element] = $content;
@@ -46,7 +48,9 @@  discard block
 block discarded – undo
46 48
 	/** Returns the data that has been bound to $element, or, if no data is bound to $element climb the DOM tree to find the data bound to a parent node*/
47 49
 	private function getData(\DomElement $element = null, $type = 'data') {
48 50
 		while ($element) {
49
-			if (isset($this->dataStorage[$element]) && isset($this->dataStorage[$element][$type])) return $this->dataStorage[$element][$type];
51
+			if (isset($this->dataStorage[$element]) && isset($this->dataStorage[$element][$type])) {
52
+				return $this->dataStorage[$element][$type];
53
+			}
50 54
 			$element = $element->parentNode;
51 55
 		}
52 56
 		return $this->data;
@@ -64,17 +68,25 @@  discard block
 block discarded – undo
64 68
 		$obj = $data;
65 69
 		$valueParser = new \Transphporm\Parser\Value($this);
66 70
 		foreach ($parts as $part) {
67
-			if ($part === '') continue;
71
+			if ($part === '') {
72
+				continue;
73
+			}
68 74
 			$part = $valueParser->parse($part, $element)[0];
69
-			if (is_callable([$obj, $part])) $obj = call_user_func([$obj, $part]); 
70
-			else $obj = $this->ifNull($obj, $part);
75
+			if (is_callable([$obj, $part])) {
76
+				$obj = call_user_func([$obj, $part]);
77
+			} else {
78
+				$obj = $this->ifNull($obj, $part);
79
+			}
71 80
 		}
72 81
 		return $obj;
73 82
 	}
74 83
 
75 84
 	private function ifNull($obj, $key) {
76
-		if (is_array($obj)) return isset($obj[$key]) ? $obj[$key] : null;
77
-		else return isset($obj->$key) ? $obj->$key : null;
85
+		if (is_array($obj)) {
86
+			return isset($obj[$key]) ? $obj[$key] : null;
87
+		} else {
88
+			return isset($obj->$key) ? $obj->$key : null;
89
+		}
78 90
 	}
79 91
 
80 92
 	public function attr($val, $element) {
@@ -100,14 +112,18 @@  discard block
 block discarded – undo
100 112
 
101 113
 		$doc = $newTemplate->output([], true)->body;
102 114
 
103
-		if (isset($val[1])) return $this->templateSubsection($val[1], $doc, $element);
115
+		if (isset($val[1])) {
116
+			return $this->templateSubsection($val[1], $doc, $element);
117
+		}
104 118
 		
105 119
 		$newNode = $element->ownerDocument->importNode($doc->documentElement, true);
106 120
 
107 121
 		$result = [];
108 122
 
109 123
 		if ($newNode->tagName === 'template') {
110
-			foreach ($newNode->childNodes as $node) $result[] = $node->cloneNode(true);
124
+			foreach ($newNode->childNodes as $node) {
125
+				$result[] = $node->cloneNode(true);
126
+			}
111 127
 		}		
112 128
 		//else $result[] = $newNode;
113 129
 
Please login to merge, or discard this patch.
src/Hook/PseudoMatcher.php 2 patches
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -77,7 +77,7 @@
 block discarded – undo
77 77
 		return false;
78 78
 	}
79 79
 
80
-	public function header($element)  {
80
+	public function header($element) {
81 81
 		if ($this->matches($element)) {
82 82
 			foreach ($this->pseudo as $pseudo) {
83 83
 				if (strpos($pseudo, 'header') === 0) return $this->getBetween($pseudo, '[', ']');
Please login to merge, or discard this patch.
Braces   +32 added lines, -12 removed lines patch added patch discarded remove patch
@@ -32,17 +32,23 @@  discard block
 block discarded – undo
32 32
 		$close = strpos($string, $closingChr, $open);
33 33
 
34 34
 		$cPos = $open+1;
35
-		while (($cPos = strpos($string, $openChr, $cPos+1)) !== false && $cPos < $close) $close = strpos($string, $closingChr, $close+1);
35
+		while (($cPos = strpos($string, $openChr, $cPos+1)) !== false && $cPos < $close) {
36
+			$close = strpos($string, $closingChr, $close+1);
37
+		}
36 38
 
37 39
 		return substr($string, $open+1, $close-$open-1);
38 40
 	}
39 41
 	
40 42
 	private function attribute($pseudo, $element) {
41 43
 		$pos = strpos($pseudo, '[');
42
-		if ($pos === false) return true;
44
+		if ($pos === false) {
45
+			return true;
46
+		}
43 47
 		
44 48
 		$name = substr($pseudo, 0, $pos);
45
-		if (!is_callable([$this->dataFunction, $name])) return true;
49
+		if (!is_callable([$this->dataFunction, $name])) {
50
+			return true;
51
+		}
46 52
 
47 53
 		$criteria = $this->betweenBrackets($pseudo, '[', ']');
48 54
 
@@ -65,16 +71,21 @@  discard block
 block discarded – undo
65 71
 	}
66 72
 
67 73
 	private function parseValue($value) {
68
-		if ($value == 'true') return true;
69
-		else if ($value == 'false') return false;
70
-		else return $value;
74
+		if ($value == 'true') {
75
+			return true;
76
+		} else if ($value == 'false') {
77
+			return false;
78
+		} else {
79
+			return $value;
80
+		}
71 81
 	}
72 82
 
73 83
 	private function getOperator($field) {
74 84
 		if ($field[strlen($field)-1] == '!') {
75 85
 			return '!';
86
+		} else {
87
+			return '';
76 88
 		}
77
-		else return '';
78 89
 	}
79 90
 
80 91
 	private function nth($pseudo, $element) {
@@ -82,8 +93,11 @@  discard block
 block discarded – undo
82 93
 			$criteria = $this->getBetween($pseudo, '(', ')');
83 94
 			$num = $this->getBetween($element->getNodePath(), '[', ']');
84 95
 			
85
-			if (is_callable([$this, $criteria])) return $this->$criteria($num);
86
-			else return $num == $criteria;
96
+			if (is_callable([$this, $criteria])) {
97
+				return $this->$criteria($num);
98
+			} else {
99
+				return $num == $criteria;
100
+			}
87 101
 			
88 102
 		}
89 103
 		return true;
@@ -100,7 +114,9 @@  discard block
 block discarded – undo
100 114
 				$xpath = new \DomXpath($element->ownerDocument);
101 115
 				
102 116
 				foreach ($xpath->query($xpathString) as $matchedElement) {
103
-					if ($element->isSameNode($matchedElement)) return false;
117
+					if ($element->isSameNode($matchedElement)) {
118
+						return false;
119
+					}
104 120
 				}
105 121
 			}
106 122
 		}
@@ -121,7 +137,9 @@  discard block
 block discarded – undo
121 137
 	public function header($element)  {
122 138
 		if ($this->matches($element)) {
123 139
 			foreach ($this->pseudo as $pseudo) {
124
-				if (strpos($pseudo, 'header') === 0) return $this->getBetween($pseudo, '[', ']');
140
+				if (strpos($pseudo, 'header') === 0) {
141
+					return $this->getBetween($pseudo, '[', ']');
142
+				}
125 143
 			}
126 144
 		}
127 145
 	}
@@ -136,7 +154,9 @@  discard block
 block discarded – undo
136 154
 
137 155
 	private function getBetween($string, $start, $end) {
138 156
 		$open = strpos($string, $start);
139
-		if ($open === false) return false;
157
+		if ($open === false) {
158
+			return false;
159
+		}
140 160
 		$close = strpos($string, $end, $open);
141 161
 		return substr($string, $open+1, $close-$open-1);
142 162
 	}
Please login to merge, or discard this patch.
src/Template.php 2 patches
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -55,7 +55,7 @@
 block discarded – undo
55 55
 		if ($document) return $this->document;
56 56
 
57 57
 
58
-		$output = ($this->document->doctype) ? $this->document->saveXml($this->document->doctype) . "\n" : '';
58
+		$output = ($this->document->doctype) ? $this->document->saveXml($this->document->doctype)."\n" : '';
59 59
 
60 60
 		if ($this->document->documentElement->tagName !== 'template') $output .= $this->document->saveXml($this->document->documentElement, LIBXML_NOEMPTYTAG);
61 61
 		else $output = $this->printDocument($this->document);
Please login to merge, or discard this patch.
Braces   +14 added lines, -5 removed lines patch added patch discarded remove patch
@@ -33,14 +33,18 @@  discard block
 block discarded – undo
33 33
 	/** Loops through all assigned hooks, runs the Xpath query and calls the hook */
34 34
 	private function processHooks() {
35 35
 		foreach ($this->hooks as list($query, $hook)) {
36
-			foreach ($this->xpath->query($query) as $element) $hook->run($element);
36
+			foreach ($this->xpath->query($query) as $element) {
37
+				$hook->run($element);
38
+			}
37 39
 		}
38 40
 	}
39 41
 
40 42
 	/** Prints out the current DomDocument as HTML */
41 43
 	private function printDocument(\DomDocument $doc) {
42 44
 		$output = '';
43
-		foreach ($doc->documentElement->childNodes as $node) $output .= $doc->saveXML($node, LIBXML_NOEMPTYTAG);
45
+		foreach ($doc->documentElement->childNodes as $node) {
46
+			$output .= $doc->saveXML($node, LIBXML_NOEMPTYTAG);
47
+		}
44 48
 		return $output;
45 49
 	}
46 50
 
@@ -52,13 +56,18 @@  discard block
 block discarded – undo
52 56
 		//Generate the document by taking only the childnodes of the template, ignoring the <template> and </template> tags
53 57
 		//TODO: Is there a faster way of doing this without string manipulation on the output or this loop through childnodes?
54 58
 		 //Either return a whole DomDocument or return the output HTML
55
-		if ($document) return $this->document;
59
+		if ($document) {
60
+			return $this->document;
61
+		}
56 62
 
57 63
 
58 64
 		$output = ($this->document->doctype) ? $this->document->saveXml($this->document->doctype) . "\n" : '';
59 65
 
60
-		if ($this->document->documentElement->tagName !== 'template') $output .= $this->document->saveXml($this->document->documentElement, LIBXML_NOEMPTYTAG);
61
-		else $output = $this->printDocument($this->document);
66
+		if ($this->document->documentElement->tagName !== 'template') {
67
+			$output .= $this->document->saveXml($this->document->documentElement, LIBXML_NOEMPTYTAG);
68
+		} else {
69
+			$output = $this->printDocument($this->document);
70
+		}
62 71
 
63 72
 		//repair empty tags. Browsers break on <script /> and <div /> so can't avoid LIBXML_NOEMPTYTAG but they also break on <base></base> so repair them
64 73
 		$output = str_replace(['></img>', '></br>', '></meta>', '></base>', '></link>', '></hr>', '></input>'], ' />', $output);
Please login to merge, or discard this patch.
src/Cache.php 1 patch
Braces   +2 added lines, -1 removed lines patch added patch discarded remove patch
@@ -20,7 +20,8 @@
 block discarded – undo
20 20
 	public function load($key, $modified = 0) {
21 21
 		if (isset($this->cache[$key]) && $this->cache[$key]['timestamp'] >= $modified) {
22 22
 			return $this->cache[$key]['content'];
23
+		} else {
24
+			return false;
23 25
 		}
24
-		else return false;
25 26
 	}
26 27
 }
27 28
\ No newline at end of file
Please login to merge, or discard this patch.
src/Rule.php 2 patches
Braces   +15 added lines, -6 removed lines patch added patch discarded remove patch
@@ -35,24 +35,33 @@
 block discarded – undo
35 35
 	}
36 36
 
37 37
 	private function timeFrequency($frequency, $time = null) {
38
-		if ($time === null) $time = time();
38
+		if ($time === null) {
39
+			$time = time();
40
+		}
39 41
 		$num = (int) $frequency;
40 42
 		$unit = strtoupper(trim(str_replace($num, '', $frequency)));
41 43
 			
42 44
 		$offset = $num * constant(self::class . '::' . $unit);
43 45
 
44
-		if ($time > $this->lastRun + $offset) return true;
45
-		else return false;
46
+		if ($time > $this->lastRun + $offset) {
47
+			return true;
48
+		} else {
49
+			return false;
50
+		}
46 51
 	}
47 52
 
48 53
 	public function shouldRun($time = null) {
49 54
 		if (isset($this->properties['update-frequency']) && $this->lastRun !== 0) {
50 55
 			$frequency = $this->properties['update-frequency'];
51 56
 			$static = ['always' => true, 'never' => false];
52
-			if (isset($static[$frequency])) return $static[$frequency];
53
-			else return $this->timeFrequency($frequency, $time);
57
+			if (isset($static[$frequency])) {
58
+				return $static[$frequency];
59
+			} else {
60
+				return $this->timeFrequency($frequency, $time);
61
+			}
54 62
 
63
+		} else {
64
+			return true;
55 65
 		}
56
-		else return true;
57 66
 	}
58 67
 }
59 68
\ No newline at end of file
Please login to merge, or discard this patch.
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -39,9 +39,9 @@
 block discarded – undo
39 39
 		$num = (int) $frequency;
40 40
 		$unit = strtoupper(trim(str_replace($num, '', $frequency)));
41 41
 			
42
-		$offset = $num * constant(self::class . '::' . $unit);
42
+		$offset = $num * constant(self::class.'::'.$unit);
43 43
 
44
-		if ($time > $this->lastRun + $offset) return true;
44
+		if ($time > $this->lastRun+$offset) return true;
45 45
 		else return false;
46 46
 	}
47 47
 
Please login to merge, or discard this patch.
src/Hook/Formatter.php 1 patch
Braces   +6 added lines, -2 removed lines patch added patch discarded remove patch
@@ -8,11 +8,15 @@
 block discarded – undo
8 8
 	}
9 9
 
10 10
 	public function format($value, $rules) {
11
-		if (!isset($rules['format'])) return $value;
11
+		if (!isset($rules['format'])) {
12
+			return $value;
13
+		}
12 14
 		$format = new \Transphporm\StringExtractor($rules['format']);
13 15
 		$options = explode(' ', $format);
14 16
 		$functionName = array_shift($options);
15
-		foreach ($options as &$f) $f = trim($format->rebuild($f), '"');
17
+		foreach ($options as &$f) {
18
+			$f = trim($format->rebuild($f), '"');
19
+		}
16 20
 
17 21
 		return $this->processFormat($options, $functionName, $value);		
18 22
 	}
Please login to merge, or discard this patch.
src/Property/Repeat.php 3 patches
Braces   +6 added lines, -2 removed lines patch added patch discarded remove patch
@@ -13,7 +13,9 @@  discard block
 block discarded – undo
13 13
 	}
14 14
 
15 15
 	public function run($value, \DomElement $element, \Transphporm\Hook\Rule $rule)  {
16
-		if ($element->getAttribute('transphporm') === 'added') return $element->parentNode->removeChild($element);
16
+		if ($element->getAttribute('transphporm') === 'added') {
17
+			return $element->parentNode->removeChild($element);
18
+		}
17 19
 
18 20
 		foreach ($value as $key => $iteration) {
19 21
 			$clone = $element->cloneNode(true);
@@ -37,7 +39,9 @@  discard block
 block discarded – undo
37 39
 
38 40
 	private function createHook($newRules, $rule) {
39 41
 		$hook = new \Transphporm\Hook\Rule($newRules, $rule->getPseudoMatcher(), $this->data);
40
-		foreach ($rule->getProperties() as $name => $property) $hook->registerProperty($name, $property);
42
+		foreach ($rule->getProperties() as $name => $property) {
43
+			$hook->registerProperty($name, $property);
44
+		}
41 45
 		return $hook;
42 46
 	}
43 47
 }
44 48
\ No newline at end of file
Please login to merge, or discard this patch.
Doc Comments   +3 added lines patch added patch discarded remove patch
@@ -35,6 +35,9 @@
 block discarded – undo
35 35
 		return false;
36 36
 	}
37 37
 
38
+	/**
39
+	 * @param \Transphporm\Hook\PropertyHook $rule
40
+	 */
38 41
 	private function createHook($newRules, $rule) {
39 42
 		$hook = new \Transphporm\Hook\PropertyHook($newRules, $rule->getPseudoMatcher(), new \Transphporm\Parser\Value($this->data));
40 43
 		foreach ($rule->getProperties() as $name => $property) $hook->registerProperty($name, $property);
Please login to merge, or discard this patch.
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -12,7 +12,7 @@
 block discarded – undo
12 12
 		$this->data = $data;
13 13
 	}
14 14
 
15
-	public function run($value, \DomElement $element, \Transphporm\Hook\PropertyHook $rule)  {
15
+	public function run($value, \DomElement $element, \Transphporm\Hook\PropertyHook $rule) {
16 16
 		if ($element->getAttribute('transphporm') === 'added') return $element->parentNode->removeChild($element);
17 17
 
18 18
 		foreach ($value as $key => $iteration) {
Please login to merge, or discard this patch.