@@ -1,6 +1,6 @@ discard block |
||
| 1 | 1 | <?php |
| 2 | 2 | |
| 3 | -declare(strict_types = 1); |
|
| 3 | +declare(strict_types=1); |
|
| 4 | 4 | |
| 5 | 5 | namespace App\Model; |
| 6 | 6 | |
@@ -112,7 +112,7 @@ discard block |
||
| 112 | 112 | User $user, |
| 113 | 113 | array $revs |
| 114 | 114 | ): array { |
| 115 | - return array_map(function ($rev) use ($pageRepo, $editRepo, $userRepo, $project, $user) { |
|
| 115 | + return array_map(function($rev) use ($pageRepo, $editRepo, $userRepo, $project, $user) { |
|
| 116 | 116 | /** Page object to be passed to the Edit constructor. */ |
| 117 | 117 | $page = Page::newFromRow($pageRepo, $project, $rev); |
| 118 | 118 | $rev['user'] = $user; |
@@ -358,8 +358,8 @@ discard block |
||
| 358 | 358 | // Must have underscores for the link to properly go to the section. |
| 359 | 359 | $sectionTitleLink = htmlspecialchars(str_replace(' ', '_', $sectionTitle)); |
| 360 | 360 | |
| 361 | - $sectionWikitext = "<a target='_blank' href='$pageUrl#$sectionTitleLink'>→</a>" . |
|
| 362 | - "<em class='text-muted'>" . htmlspecialchars($sectionTitle) . ":</em> "; |
|
| 361 | + $sectionWikitext = "<a target='_blank' href='$pageUrl#$sectionTitleLink'>→</a>". |
|
| 362 | + "<em class='text-muted'>".htmlspecialchars($sectionTitle).":</em> "; |
|
| 363 | 363 | $summary = str_replace($sectionMatch[0][0], $sectionWikitext, $summary); |
| 364 | 364 | } |
| 365 | 365 | |
@@ -406,7 +406,7 @@ discard block |
||
| 406 | 406 | */ |
| 407 | 407 | public function getDiffUrl(): string |
| 408 | 408 | { |
| 409 | - return rtrim($this->getProject()->getUrlForPage('Special:Diff/' . $this->id), '/'); |
|
| 409 | + return rtrim($this->getProject()->getUrlForPage('Special:Diff/'.$this->id), '/'); |
|
| 410 | 410 | } |
| 411 | 411 | |
| 412 | 412 | /** |
@@ -415,7 +415,7 @@ discard block |
||
| 415 | 415 | */ |
| 416 | 416 | public function getPermaUrl(): string |
| 417 | 417 | { |
| 418 | - return rtrim($this->getProject()->getUrlForPage('Special:PermaLink/' . $this->id), '/'); |
|
| 418 | + return rtrim($this->getProject()->getUrlForPage('Special:PermaLink/'.$this->id), '/'); |
|
| 419 | 419 | } |
| 420 | 420 | |
| 421 | 421 | /** |
@@ -494,10 +494,10 @@ discard block |
||
| 494 | 494 | $ret['reverted'] = $this->reverted; |
| 495 | 495 | } |
| 496 | 496 | if ($includeUsername) { |
| 497 | - $ret = [ 'username' => $this->getUser()->getUsername() ] + $ret; |
|
| 497 | + $ret = ['username' => $this->getUser()->getUsername()]+$ret; |
|
| 498 | 498 | } |
| 499 | 499 | if ($includeProject) { |
| 500 | - $ret = [ 'project' => $this->getProject()->getDomain() ] + $ret; |
|
| 500 | + $ret = ['project' => $this->getProject()->getDomain()]+$ret; |
|
| 501 | 501 | } |
| 502 | 502 | |
| 503 | 503 | return $ret; |