@@ -101,7 +101,7 @@ |
||
101 | 101 | */ |
102 | 102 | protected function addRule($ruleName, $arguments) |
103 | 103 | { |
104 | - $ruleClass = "Inet\Transformation\Rule\\" . $ruleName; |
|
104 | + $ruleClass = "Inet\Transformation\Rule\\".$ruleName; |
|
105 | 105 | if (!class_exists($ruleClass)) { |
106 | 106 | throw new InvalidRuleException("The rule '$ruleName' does not exist"); |
107 | 107 | } |
@@ -45,7 +45,7 @@ |
||
45 | 45 | unset($arguments[0]); |
46 | 46 | // Functions is callable ? |
47 | 47 | if (!is_callable($callable)) { |
48 | - throw new TransformationException($callable . ' is not callable'); |
|
48 | + throw new TransformationException($callable.' is not callable'); |
|
49 | 49 | } |
50 | 50 | |
51 | 51 | // Transform it by calling the method and sending arguments |
@@ -42,6 +42,6 @@ |
||
42 | 42 | $before = $arguments[0]; |
43 | 43 | $after = (array_key_exists(1, $arguments) ? $arguments[1] : ''); |
44 | 44 | |
45 | - return $before . $input . $after; |
|
45 | + return $before.$input.$after; |
|
46 | 46 | } |
47 | 47 | } |
@@ -58,7 +58,7 @@ |
||
58 | 58 | if (is_null($output)) { |
59 | 59 | $pregErr = preg_last_error(); |
60 | 60 | $pregMsg = array_key_exists($pregErr, $this->pregErrs) ? $this->pregErrs[$pregErr] : 'Unknown error'; |
61 | - $msg = 'ReplaceRegexp was not able to transform your string: ' . $pregMsg; |
|
61 | + $msg = 'ReplaceRegexp was not able to transform your string: '.$pregMsg; |
|
62 | 62 | throw new TransformationException($msg); |
63 | 63 | } |
64 | 64 |
@@ -49,7 +49,7 @@ |
||
49 | 49 | $pattern = '|^(?!'.$protocol.')(.+)$|'; |
50 | 50 | preg_match($pattern, $input, $matches); |
51 | 51 | if (!empty($matches)) { |
52 | - $input = $protocol . '://' . $input; |
|
52 | + $input = $protocol.'://'.$input; |
|
53 | 53 | } |
54 | 54 | |
55 | 55 | return $input; |
@@ -43,7 +43,7 @@ |
||
43 | 43 | |
44 | 44 | if (!is_array($input)) { |
45 | 45 | throw new NotTransformableException('Rule Implode can transform an array. ' |
46 | - . gettype($input) . ' found in input'); |
|
46 | + . gettype($input).' found in input'); |
|
47 | 47 | } |
48 | 48 | |
49 | 49 | // Transform it |
@@ -99,7 +99,7 @@ discard block |
||
99 | 99 | $string = preg_replace('/^(\^\^,\^)|(\^,\^\^)$/', '^', $string); |
100 | 100 | |
101 | 101 | // Get the inner part of the string without leading|trailing ^ chars |
102 | - $string = substr(substr($string, 1), 0, strlen($string) -2); |
|
102 | + $string = substr(substr($string, 1), 0, strlen($string) - 2); |
|
103 | 103 | } |
104 | 104 | |
105 | 105 | return explode('^,^', $string); |
@@ -111,7 +111,7 @@ discard block |
||
111 | 111 | return ""; |
112 | 112 | } |
113 | 113 | |
114 | - $string = "^" . implode('^,^', $arr) . "^"; |
|
114 | + $string = "^".implode('^,^', $arr)."^"; |
|
115 | 115 | |
116 | 116 | return $string; |
117 | 117 | } |
@@ -47,7 +47,7 @@ |
||
47 | 47 | $output = $slugify->slugify($input); |
48 | 48 | } catch (\Exception $e) { |
49 | 49 | throw new NotTransformableException( |
50 | - 'Rule Slugify: Unable to transform input (' . var_export($input, true) . ')' |
|
50 | + 'Rule Slugify: Unable to transform input ('.var_export($input, true).')' |
|
51 | 51 | ); |
52 | 52 | } |
53 | 53 |