@@ -129,7 +129,7 @@ discard block |
||
129 | 129 | if ( |
130 | 130 | (is_int($datetype) && $datetype !== \IntlDateFormatter::NONE) || |
131 | 131 | (is_int($timetype) && $timetype !== \IntlDateFormatter::NONE) |
132 | - ){ |
|
132 | + ) { |
|
133 | 133 | $pattern = \IntlDateFormatter::create( |
134 | 134 | \Locale::getDefault(), |
135 | 135 | is_int($datetype) ? $datetype : \IntlDateFormatter::NONE, |
@@ -194,7 +194,7 @@ discard block |
||
194 | 194 | * @param string $calendar 'gregorian' or 'traditional' |
195 | 195 | * @return string |
196 | 196 | */ |
197 | - public function localTime($date, $format='short', $calendar='gregorian') |
|
197 | + public function localTime($date, $format = 'short', $calendar = 'gregorian') |
|
198 | 198 | { |
199 | 199 | return $this->formatLocal($date, false, $format, $calendar); |
200 | 200 | } |
@@ -119,7 +119,7 @@ discard block |
||
119 | 119 | if ($match[1]) $protocol = $match[1]; |
120 | 120 | $link = $match[2] ?: $match[3]; |
121 | 121 | |
122 | - return '<' . array_push($links, '<a' . $attr . ' href="' . $protocol . '://' . $link . '">' |
|
122 | + return '<' . array_push($links, '<a' . $attr . ' href="' . $protocol . '://' . $link . '">' |
|
123 | 123 | . rtrim($link, '/') . '</a>') . '>'; |
124 | 124 | }, $text); |
125 | 125 | } |
@@ -136,7 +136,7 @@ discard block |
||
136 | 136 | $regexp = '~([^\s<>]+?@[^\s<>]+?\.[^\s<>]+)(?<![\.,:;\?!\'"\|])~'; |
137 | 137 | |
138 | 138 | return preg_replace_callback($regexp, function ($match) use (&$links, $attr) { |
139 | - return '<' . array_push($links, '<a' . $attr . ' href="mailto:' . $match[1] . '">' . $match[1] . '</a>') |
|
139 | + return '<' . array_push($links, '<a' . $attr . ' href="mailto:' . $match[1] . '">' . $match[1] . '</a>') |
|
140 | 140 | . '>'; |
141 | 141 | }, $text); |
142 | 142 | } |
@@ -154,7 +154,7 @@ discard block |
||
154 | 154 | protected function linkifyOther($protocol, $text, array &$links, $attr, $mode) |
155 | 155 | { |
156 | 156 | if (strpos($protocol, ':') === false) { |
157 | - $protocol .= in_array($protocol, ['ftp', 'tftp', 'ssh', 'scp']) ? '://' : ':'; |
|
157 | + $protocol .= in_array($protocol, ['ftp', 'tftp', 'ssh', 'scp']) ? '://' : ':'; |
|
158 | 158 | } |
159 | 159 | |
160 | 160 | $regexp = $mode != 'all' |
@@ -162,7 +162,7 @@ discard block |
||
162 | 162 | : '~([^\s<>]+)(?<![\.,:])~i'; |
163 | 163 | |
164 | 164 | return preg_replace_callback($regexp, function ($match) use ($protocol, &$links, $attr) { |
165 | - return '<' . array_push($links, '<a' . $attr . ' href="' . $protocol . $match[1] . '">' . $match[1] |
|
165 | + return '<' . array_push($links, '<a' . $attr . ' href="' . $protocol . $match[1] . '">' . $match[1] |
|
166 | 166 | . '</a>') . '>'; |
167 | 167 | }, $text); |
168 | 168 | } |