@@ -17,7 +17,7 @@ |
||
| 17 | 17 | */ |
| 18 | 18 | protected function getCache() |
| 19 | 19 | { |
| 20 | - return Injector::inst()->get(CacheInterface::class . '.CurlLinkChecker'); |
|
| 20 | + return Injector::inst()->get(CacheInterface::class.'.CurlLinkChecker'); |
|
| 21 | 21 | } |
| 22 | 22 | |
| 23 | 23 | /** |
@@ -19,7 +19,7 @@ |
||
| 19 | 19 | |
| 20 | 20 | public function getTitle() |
| 21 | 21 | { |
| 22 | - return _t(__CLASS__ . '.TITLE', 'Checking for external broken links'); |
|
| 22 | + return _t(__CLASS__.'.TITLE', 'Checking for external broken links'); |
|
| 23 | 23 | } |
| 24 | 24 | |
| 25 | 25 | public function getJobType() |
@@ -74,10 +74,9 @@ |
||
| 74 | 74 | $response = HTTPResponse::create('', $code); |
| 75 | 75 | // Assume that $code = 0 means there was no response |
| 76 | 76 | $description = $code ? |
| 77 | - $response->getStatusDescription() : |
|
| 78 | - _t(__CLASS__ . '.NOTAVAILABLE', 'Server Not Available'); |
|
| 77 | + $response->getStatusDescription() : _t(__CLASS__.'.NOTAVAILABLE', 'Server Not Available'); |
|
| 79 | 78 | } catch (InvalidArgumentException $e) { |
| 80 | - $description = _t(__CLASS__ . '.UNKNOWNRESPONSE', 'Unknown Response Code'); |
|
| 79 | + $description = _t(__CLASS__.'.UNKNOWNRESPONSE', 'Unknown Response Code'); |
|
| 81 | 80 | } |
| 82 | 81 | |
| 83 | 82 | return sprintf("%d (%s)", $code, $description); |
@@ -25,7 +25,7 @@ discard block |
||
| 25 | 25 | */ |
| 26 | 26 | public function title() |
| 27 | 27 | { |
| 28 | - return _t(__CLASS__ . '.EXTERNALBROKENLINKS', "External broken links report"); |
|
| 28 | + return _t(__CLASS__.'.EXTERNALBROKENLINKS', "External broken links report"); |
|
| 29 | 29 | } |
| 30 | 30 | |
| 31 | 31 | public function columns() |
@@ -34,7 +34,7 @@ discard block |
||
| 34 | 34 | "Created" => "Checked", |
| 35 | 35 | 'Link' => array( |
| 36 | 36 | 'title' => 'External Link', |
| 37 | - 'formatting' => function ($value, $item) { |
|
| 37 | + 'formatting' => function($value, $item) { |
|
| 38 | 38 | return sprintf( |
| 39 | 39 | '<a target="_blank" href="%s">%s</a>', |
| 40 | 40 | Convert::raw2att($item->Link), |
@@ -45,7 +45,7 @@ discard block |
||
| 45 | 45 | 'HTTPCodeDescription' => 'HTTP Error Code', |
| 46 | 46 | "Title" => array( |
| 47 | 47 | "title" => 'Page link is on', |
| 48 | - 'formatting' => function ($value, $item) { |
|
| 48 | + 'formatting' => function($value, $item) { |
|
| 49 | 49 | $page = $item->Page(); |
| 50 | 50 | return sprintf( |
| 51 | 51 | '<a href="%s">%s</a>', |
@@ -83,7 +83,7 @@ discard block |
||
| 83 | 83 | |
| 84 | 84 | $fields = parent::getCMSFields(); |
| 85 | 85 | |
| 86 | - $runReportButton = FormAction::create('createReport', _t(__CLASS__ . '.RUNREPORT', 'Create new report')) |
|
| 86 | + $runReportButton = FormAction::create('createReport', _t(__CLASS__.'.RUNREPORT', 'Create new report')) |
|
| 87 | 87 | ->addExtraClass('btn-primary external-links-report__create-report') |
| 88 | 88 | ->setUseButtonTag(true); |
| 89 | 89 | $fields->push($runReportButton); |
@@ -19,7 +19,7 @@ discard block |
||
| 19 | 19 | class CheckExternalLinksTask extends BuildTask |
| 20 | 20 | { |
| 21 | 21 | private static $dependencies = [ |
| 22 | - 'LinkChecker' => '%$' . LinkChecker::class |
|
| 22 | + 'LinkChecker' => '%$'.LinkChecker::class |
|
| 23 | 23 | ]; |
| 24 | 24 | |
| 25 | 25 | private static $segment = 'CheckExternalLinksTask'; |
@@ -198,7 +198,7 @@ discard block |
||
| 198 | 198 | try { |
| 199 | 199 | $page->write(); |
| 200 | 200 | } catch (ValidationException $ex) { |
| 201 | - $this->log("Exception caught for {$page->Title}, skipping. Message: " . $ex->getMessage()); |
|
| 201 | + $this->log("Exception caught for {$page->Title}, skipping. Message: ".$ex->getMessage()); |
|
| 202 | 202 | continue; |
| 203 | 203 | } |
| 204 | 204 | |
@@ -49,9 +49,9 @@ |
||
| 49 | 49 | public function provideI18nEntities() |
| 50 | 50 | { |
| 51 | 51 | return [ |
| 52 | - __CLASS__ . '.SINGULARNAME' => 'Broken External Page Track Status', |
|
| 53 | - __CLASS__ . '.PLURALNAME' => 'Broken External Page Track Statuses', |
|
| 54 | - __CLASS__ . '.PLURALS' => [ |
|
| 52 | + __CLASS__.'.SINGULARNAME' => 'Broken External Page Track Status', |
|
| 53 | + __CLASS__.'.PLURALNAME' => 'Broken External Page Track Statuses', |
|
| 54 | + __CLASS__.'.PLURALS' => [ |
|
| 55 | 55 | 'one' => 'A Broken External Page Track Status', |
| 56 | 56 | 'other' => '{count} Broken External Page Track Statuses', |
| 57 | 57 | ], |