Skip to content
This repository has been archived by the owner on Mar 31, 2022. It is now read-only.

Update friendsoftwig/twigcs requirement from ^4.0 to ^5.0 #28

Open
wants to merge 2 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@
},
"require-dev": {
"friendsofphp/php-cs-fixer": "^2.17",
"friendsoftwig/twigcs": "^4.0",
"friendsoftwig/twigcs": "^5.0",
"phpunit/phpunit": "^9",
"squizlabs/php_codesniffer": "^3.5",
"symfony/phpunit-bridge": "^5.0",
Expand Down
2 changes: 1 addition & 1 deletion src/Entity/PageTrait/PageRedirectionTrait.php
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ protected function manageRedirection()
$code = (int) (trim($match[0]));
$url = preg_replace('/ [1-5][0-9]{2}$/', '', $url);
}
if (filter_var($url, FILTER_VALIDATE_URL)) {
if (filter_var($url, \FILTER_VALIDATE_URL)) {
$this->redirectionUrl = $url;
$this->redirectionCode = $code;

Expand Down
2 changes: 1 addition & 1 deletion src/Entity/SharedTrait/CustomPropertiesTrait.php
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@ public function getStandAloneCustomProperties(): string
$standStandAloneCustomPropertiesParsed = array_filter(
$customPropertiesParsed,
[$this, 'isStandAloneCustomProperty'],
ARRAY_FILTER_USE_KEY
\ARRAY_FILTER_USE_KEY
);
if (! $standStandAloneCustomPropertiesParsed) {
return '';
Expand Down
3 changes: 1 addition & 2 deletions src/Extension/Admin/Page/Admin.php
Original file line number Diff line number Diff line change
Expand Up @@ -12,12 +12,11 @@

class Admin extends AbstractAdmin implements AdminInterface
{
public $supportsPreviewMode = true;

use AdminTrait;
use FormFieldsOpenGraphTrait;
use FormFieldsTrait;
use SharedFormFieldsTrait;
public $supportsPreviewMode = true;

protected $messagePrefix = 'admin.page';

Expand Down
2 changes: 1 addition & 1 deletion src/Extension/Filter/Filters/Date.php
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ public function convertDateShortCode($string, $locale = null)
{
//var_dump($string); exit;
if ($locale) {
setlocale(LC_TIME, self::convertLocale($locale));
setlocale(\LC_TIME, self::convertLocale($locale));
}

//$string = preg_replace('/date\([\'"]?([a-z% ]+)[\'"]?\)/i',
Expand Down
2 changes: 1 addition & 1 deletion src/Extension/StaticGenerator/StaticAppGenerator.php
Original file line number Diff line number Diff line change
Expand Up @@ -359,7 +359,7 @@ protected function addRedirection($from, string $to = '', $code = 0)
$this->redirections .= $from instanceof Page ? $this->router->generate($from->getRealSlug()) : $from;
$this->redirections .= ' ';
$this->redirections .= $to ?: $from->getRedirection();
$this->redirections .= PHP_EOL;
$this->redirections .= \PHP_EOL;
}

protected function generatePages(): void
Expand Down
2 changes: 1 addition & 1 deletion src/Service/VichUploadPropertyNamer.php
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ private function getExtension(UploadedFile $file): ?string
{
$originalName = $file->getClientOriginalName();

if ($extension = pathinfo($originalName, PATHINFO_EXTENSION)) {
if ($extension = pathinfo($originalName, \PATHINFO_EXTENSION)) {
return strtolower($extension);
}

Expand Down