@@ -159,9 +159,9 @@ discard block |
||
| 159 | 159 | public function parse($source, $caseInsensitive = false) |
| 160 | 160 | { |
| 161 | 161 | foreach ($this->enabledParsers as $name => $parser) { |
| 162 | - $pattern = ($caseInsensitive) ? $parser['pattern'] . 'i' : $parser['pattern']; |
|
| 162 | + $pattern = ($caseInsensitive) ? $parser[ 'pattern' ] . 'i' : $parser[ 'pattern' ]; |
|
| 163 | 163 | |
| 164 | - $source = $this->searchAndReplace($pattern, $parser['replace'], $source); |
|
| 164 | + $source = $this->searchAndReplace($pattern, $parser[ 'replace' ], $source); |
|
| 165 | 165 | } |
| 166 | 166 | |
| 167 | 167 | return $source; |
@@ -176,7 +176,7 @@ discard block |
||
| 176 | 176 | public function stripBBCodeTags($source) |
| 177 | 177 | { |
| 178 | 178 | foreach ($this->parsers as $name => $parser) { |
| 179 | - $source = $this->searchAndReplace($parser['pattern'] . 'i', $parser['content'], $source); |
|
| 179 | + $source = $this->searchAndReplace($parser[ 'pattern' ] . 'i', $parser[ 'content' ], $source); |
|
| 180 | 180 | } |
| 181 | 181 | |
| 182 | 182 | return $source; |
@@ -271,13 +271,13 @@ discard block |
||
| 271 | 271 | */ |
| 272 | 272 | public function setParser($name, $pattern, $replace, $content) |
| 273 | 273 | { |
| 274 | - $this->parsers[$name] = [ |
|
| 274 | + $this->parsers[ $name ] = [ |
|
| 275 | 275 | 'pattern' => $pattern, |
| 276 | 276 | 'replace' => $replace, |
| 277 | 277 | 'content' => $content, |
| 278 | 278 | ]; |
| 279 | 279 | |
| 280 | - $this->enabledParsers[$name] = [ |
|
| 280 | + $this->enabledParsers[ $name ] = [ |
|
| 281 | 281 | 'pattern' => $pattern, |
| 282 | 282 | 'replace' => $replace, |
| 283 | 283 | 'content' => $content, |
@@ -13,7 +13,7 @@ |
||
| 13 | 13 | */ |
| 14 | 14 | public function register() |
| 15 | 15 | { |
| 16 | - $this->app->bind('laravel-bbcode', function () { |
|
| 16 | + $this->app->bind('laravel-bbcode', function() { |
|
| 17 | 17 | return new BBCodeParser; |
| 18 | 18 | }); |
| 19 | 19 | } |