Completed
Push — master ( 205dba...c71ac0 )
by smiley
03:14
created
src/Modules/Html5/Links.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -40,7 +40,7 @@
 block discarded – undo
40 40
 			return '';
41 41
 		}
42 42
 
43
-		$url = $this->checkUrl($this->bbtag() ? : $this->content);
43
+		$url = $this->checkUrl($this->bbtag() ?: $this->content);
44 44
 		$host = parse_url($url, PHP_URL_HOST);
45 45
 		$target = (!empty($host) && (isset($_SERVER['SERVER_NAME']) && $host === $_SERVER['SERVER_NAME']))
46 46
 			|| empty($host) ? 'self' : 'blank';
Please login to merge, or discard this patch.
src/Modules/Markdown/StyledText.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -41,9 +41,9 @@
 block discarded – undo
41 41
 
42 42
 		$str = [
43 43
 			'b'      => '**', // bold
44
-			'c'      => '`',  // inline code
44
+			'c'      => '`', // inline code
45 45
 			'del'    => '~~', // strikethrough
46
-			'i'      => '_',  // italic
46
+			'i'      => '_', // italic
47 47
 			's'      => '~~', // strikethrough
48 48
 			'strong' => '**', // bold
49 49
 		][$this->tag];
Please login to merge, or discard this patch.
src/ParserExtensionInterface.php 1 patch
Doc Comments   +1 added lines patch added patch discarded remove patch
@@ -23,6 +23,7 @@
 block discarded – undo
23 23
 	 * ParserExtensionInterface constructor.
24 24
 	 *
25 25
 	 * @param \chillerlan\bbcode\ParserOptions|null $options
26
+	 * @return void
26 27
 	 */
27 28
 	public function __construct(ParserOptions $options = null);
28 29
 
Please login to merge, or discard this patch.
src/Modules/Html5/Video.php 2 patches
Indentation   +7 added lines, -7 removed lines patch added patch discarded remove patch
@@ -99,11 +99,11 @@  discard block
 block discarded – undo
99 99
 	protected function flashPlayer(string $video_url):string{
100 100
 
101 101
 		return '<div'.$this->getCssClass($this->cssclass).'>'
102
-		       .'<object type="application/x-shockwave-flash" data="'.$video_url.'">'
103
-		       .'<param name="allowfullscreen" value="true">'
104
-		       .'<param name="wmode" value="opaque" />'
105
-		       .'<param name="movie" value="'.$video_url.'" />'
106
-		       .'</object></div>';
102
+			   .'<object type="application/x-shockwave-flash" data="'.$video_url.'">'
103
+			   .'<param name="allowfullscreen" value="true">'
104
+			   .'<param name="wmode" value="opaque" />'
105
+			   .'<param name="movie" value="'.$video_url.'" />'
106
+			   .'</object></div>';
107 107
 	}
108 108
 
109 109
 	/**
@@ -114,7 +114,7 @@  discard block
 block discarded – undo
114 114
 	protected function embedPlayer(string $video_url):string{
115 115
 
116 116
 		return '<div'.$this->getCssClass($this->cssclass).'>'
117
-		       .'<iframe src="'.$video_url.'" allowfullscreen></iframe></div>';
117
+			   .'<iframe src="'.$video_url.'" allowfullscreen></iframe></div>';
118 118
 	}
119 119
 
120 120
 	/**
@@ -123,7 +123,7 @@  discard block
 block discarded – undo
123 123
 	protected function html5Player():string{
124 124
 
125 125
 		return '<video src="'.$this->checkUrl($this->content).'"'
126
-		       .$this->getCssClass($this->cssclass).' preload="auto" controls="true"></video>';
126
+			   .$this->getCssClass($this->cssclass).' preload="auto" controls="true"></video>';
127 127
 	}
128 128
 
129 129
 	/**
Please login to merge, or discard this patch.
Unused Use Statements   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -12,8 +12,8 @@
 block discarded – undo
12 12
 
13 13
 namespace chillerlan\bbcode\Modules\Html5;
14 14
 
15
-use chillerlan\bbcode\Modules\ModuleInterface;
16 15
 use chillerlan\TinyCurl\RequestTrait;
16
+use chillerlan\bbcode\Modules\ModuleInterface;
17 17
 
18 18
 /**
19 19
  * Transforms several video tags into HTML5
Please login to merge, or discard this patch.
src/Modules/Html5/Tables.php 1 patch
Indentation   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -73,8 +73,8 @@  discard block
 block discarded – undo
73 73
 	protected function table():string{
74 74
 
75 75
 		return '<table'.$this->getCssClass(['bb-table'])
76
-		       .$this->getStyle(['width' => $this->getAttribute('width')])
77
-		       .'>'.$this->eol($this->content).'</table>';
76
+			   .$this->getStyle(['width' => $this->getAttribute('width')])
77
+			   .'>'.$this->eol($this->content).'</table>';
78 78
 	}
79 79
 
80 80
 	/**
@@ -140,8 +140,8 @@  discard block
 block discarded – undo
140 140
 		}
141 141
 
142 142
 		return '<'.$this->tag.$colspan.$rowspan.$abbr.$this->getCellStyle().'>'
143
-		       .$this->eol($this->content, $this->eol_token)
144
-		       .'</'.$this->tag.'>';
143
+			   .$this->eol($this->content, $this->eol_token)
144
+			   .'</'.$this->tag.'>';
145 145
 	}
146 146
 
147 147
 	/**
Please login to merge, or discard this patch.
src/Modules/BaseModuleAbstract.php 2 patches
Doc Comments   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -248,7 +248,7 @@  discard block
 block discarded – undo
248 248
 
249 249
 	 * @param string $name      the desired attributes name
250 250
 	 * @param array  $whitelist an array with whitelisted key -> value pairs
251
-	 * @param mixed  $default   [optional] a default value in case the attribute isn't set, defaults to false
251
+	 * @param string  $default   [optional] a default value in case the attribute isn't set, defaults to false
252 252
 	 *
253 253
 	 * @return mixed boolean if no $default is set, otherwise the whitelist value to the given key in case it exists or $default
254 254
 	 */
@@ -262,7 +262,7 @@  discard block
 block discarded – undo
262 262
 	 * Checks if the current tag is whitelisted
263 263
 	 *
264 264
 	 * @param array $whitelist an array with whitelisted tag names
265
-	 * @param mixed $default   [optional] a default value in case the tag isn't whitelisted
265
+	 * @param string $default   [optional] a default value in case the tag isn't whitelisted
266 266
 	 *
267 267
 	 * @return mixed boolean if no $default is set, otherwise the whitelisted tag or $default
268 268
 	 */
@@ -311,7 +311,7 @@  discard block
 block discarded – undo
311 311
 	 * shorthand for self::attributeIn('__BBTAG__', $array)
312 312
 	 *
313 313
 	 * @param array $array
314
-	 * @param mixed $default
314
+	 * @param string $default
315 315
 	 *
316 316
 	 * @return mixed
317 317
 	 */
@@ -324,7 +324,7 @@  discard block
 block discarded – undo
324 324
 	 *
325 325
 	 * @param string $url the URL to check
326 326
 	 *
327
-	 * @return bool|string the url if valid, otherwise false
327
+	 * @return false|string the url if valid, otherwise false
328 328
 	 */
329 329
 	public function checkUrl(string $url){
330 330
 		if(filter_var($url, FILTER_VALIDATE_URL) === false){
Please login to merge, or discard this patch.
Indentation   -1 removed lines patch added patch discarded remove patch
@@ -246,7 +246,6 @@
 block discarded – undo
246 246
 
247 247
 	/**
248 248
 	 * Checks if an attribute exists and if it exists as key in a whitelist
249
-
250 249
 	 * @param string $name      the desired attributes name
251 250
 	 * @param array  $whitelist an array with whitelisted key -> value pairs
252 251
 	 * @param mixed  $default   [optional] a default value in case the attribute isn't set, defaults to false
Please login to merge, or discard this patch.
src/Language/LanguageAbstract.php 1 patch
Doc Comments   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -40,7 +40,7 @@
 block discarded – undo
40 40
 	 * @param string $name
41 41
 	 * @param array  $arguments
42 42
 	 *
43
-	 * @return mixed
43
+	 * @return string
44 44
 	 */
45 45
 	public function __call(string $name, array $arguments){
46 46
 		return $this->string($name, ...$arguments);
Please login to merge, or discard this patch.
src/Language/LanguageInterface.php 1 patch
Doc Comments   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -40,7 +40,7 @@  discard block
 block discarded – undo
40 40
 	 * @param string $name
41 41
 	 * @param array  $arguments
42 42
 	 *
43
-	 * @return mixed
43
+	 * @return string
44 44
 	 */
45 45
 	public function __call(string $name, array $arguments);
46 46
 
@@ -50,7 +50,7 @@  discard block
 block discarded – undo
50 50
 	 * @param string $key
51 51
 	 * @param string $LanguageInterface (a LanguageInterface FQCN)
52 52
 	 *
53
-	 * @return mixed
53
+	 * @return string
54 54
 	 * @throws \chillerlan\bbcode\BBCodeException
55 55
 	 */
56 56
 	public function string(string $key, string $LanguageInterface = null);
Please login to merge, or discard this patch.
src/Parser.php 1 patch
Doc Comments   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -198,7 +198,7 @@  discard block
 block discarded – undo
198 198
 	/**
199 199
 	 * strng regexp bbcode killer
200 200
 	 *
201
-	 * @param string|array $bbcode BBCode as string or matches as array - callback from preg_replace_callback()
201
+	 * @param string $bbcode BBCode as string or matches as array - callback from preg_replace_callback()
202 202
 	 *
203 203
 	 * @return string
204 204
 	 * @throws \chillerlan\bbcode\BBCodeException
@@ -353,9 +353,9 @@  discard block
 block discarded – undo
353 353
 	/**
354 354
 	 * testing...
355 355
 	 *
356
-	 * @param      $preg_error
356
+	 * @param      integer $preg_error
357 357
 	 *
358
-	 * @param null $tag
358
+	 * @param string|null $tag
359 359
 	 *
360 360
 	 * @return void
361 361
 	 * @throws \chillerlan\bbcode\BBCodeException
Please login to merge, or discard this patch.