Skip to content

Commit 1d1a7a1

Browse files
committed
Update composer
Signed-off-by: Maxime Gervais <gervais.maxime@gmail.com>
1 parent 9a4c844 commit 1d1a7a1

9 files changed

Lines changed: 35 additions & 76 deletions

File tree

.github/workflows/MediaArea-Website_Checks.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ jobs:
2525
php-version: 7.2
2626
extensions: gd
2727
ini-values: memory_limit=-1
28-
tools: composer:v1
28+
tools: composer:2.2
2929
coverage: none
3030
- name: Get composer cache directory
3131
id: composer-cache
@@ -41,7 +41,7 @@ jobs:
4141
cp app/config/parameters.yml.ci app/config/parameters.yml
4242
- name: Install dependencies
4343
run: |
44-
composer require --no-progress --dev friendsofphp/php-cs-fixer:2.13.* phpmd/phpmd:2.7.* --prefer-dist --no-suggest --ansi
44+
composer require --no-progress --dev friendsofphp/php-cs-fixer:2.15.* phpmd/phpmd:2.7.* --prefer-dist --no-suggest --ansi
4545
- name: Configure
4646
run: |
4747
php bin/console doctrine:database:create --env=test --if-not-exists
@@ -53,7 +53,7 @@ jobs:
5353
php bin/console mediaarea:user:donor beta@mediaarea.net 30
5454
- name: Check
5555
run: |
56-
vendor/bin/php-cs-fixer --dry-run --stop-on-violation --using-cache=no fix src/
56+
vendor/bin/php-cs-fixer --verbose --dry-run --using-cache=no fix src/
5757
vendor/bin/phpmd src/ text phpmd.xml
5858
php bin/console lint:twig app/ src/
5959
# php bin/console lint:xliff src/

composer.json

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,6 @@
1313
},
1414
"require": {
1515
"php": ">=5.5.9",
16-
"brightnucleus/geolite2-country": "^0.2.3",
1716
"doctrine/doctrine-bundle": "^1.6",
1817
"doctrine/doctrine-migrations-bundle": "^1.0",
1918
"doctrine/orm": "^2.5",

composer.lock

Lines changed: 0 additions & 40 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/AppBundle/Tests/Lib/PaginatorTest.php

Lines changed: 15 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -20,11 +20,11 @@ public function testGetTotalPages($items, $itemsPerPage, $expected)
2020
public function totalPagesProvider()
2121
{
2222
return [
23-
[100, 10, 10],
24-
[101, 10, 11],
25-
[109, 10, 11],
26-
[5, 10, 1],
27-
];
23+
[100, 10, 10],
24+
[101, 10, 11],
25+
[109, 10, 11],
26+
[5, 10, 1],
27+
];
2828
}
2929

3030
/**
@@ -110,9 +110,9 @@ public function testRouteWithParams($items, $currentPage, $expectedRoute, $expec
110110

111111
$this->assertEquals($expectedRoute, $paginator->getPageRoute($currentPage));
112112
$this->assertEquals(
113-
array_merge($routeParams, $expectedRouteParams),
114-
$paginator->getPageRouteParams($currentPage)
115-
);
113+
array_merge($routeParams, $expectedRouteParams),
114+
$paginator->getPageRouteParams($currentPage)
115+
);
116116
}
117117

118118
/**
@@ -128,12 +128,12 @@ public function testIsCurrent($items, $currentPage, $page, $expectedCurrent)
128128
public function isCurrentProvider()
129129
{
130130
return [
131-
[95, 1, 1, true],
132-
[95, 1, 2, false],
133-
[95, 2, 1, false],
134-
[95, 2, 2, true],
135-
[95, 10, 1, false],
136-
[95, 10, 10, true],
137-
];
131+
[95, 1, 1, true],
132+
[95, 1, 2, false],
133+
[95, 2, 1, false],
134+
[95, 2, 2, true],
135+
[95, 10, 1, false],
136+
[95, 10, 10, true],
137+
];
138138
}
139139
}

src/BlogBundle/Controller/DefaultController.php

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -63,10 +63,10 @@ public function feedAction()
6363
{
6464
$posts = new Posts($this->getParameter('blog.files.path'));
6565
$showPosts = new LimitIterator(
66-
$posts,
67-
0,
68-
self::POSTS_PER_PAGE
69-
);
66+
$posts,
67+
0,
68+
self::POSTS_PER_PAGE
69+
);
7070

7171
// Throw 404 if there is no post
7272
if (0 == iterator_count($showPosts)) {
@@ -85,10 +85,10 @@ public function listingByTagAction(Request $request, int $page, $tag)
8585
{
8686
$posts = new PostsTagFilter(new Posts($this->getParameter('blog.files.path')), $tag);
8787
$showPosts = new LimitIterator(
88-
$posts,
89-
($page - 1) * self::POSTS_PER_PAGE,
90-
self::POSTS_PER_PAGE
91-
);
88+
$posts,
89+
($page - 1) * self::POSTS_PER_PAGE,
90+
self::POSTS_PER_PAGE
91+
);
9292

9393
// Throw 404 if there is no post
9494
if (0 == iterator_count($showPosts)) {
@@ -129,10 +129,10 @@ public function listingByTagFeedAction($tag)
129129
{
130130
$posts = new PostsTagFilter(new Posts($this->getParameter('blog.files.path')), $tag);
131131
$showPosts = new LimitIterator(
132-
$posts,
133-
0,
134-
self::POSTS_PER_PAGE
135-
);
132+
$posts,
133+
0,
134+
self::POSTS_PER_PAGE
135+
);
136136

137137
// Throw 404 if there is no post
138138
if (0 == iterator_count($showPosts)) {

src/MediaConchOnlineBundle/Form/Type/CheckerBaseFormType.php

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ public function __construct(
2525
EntityManagerInterface $em,
2626
SettingsManager $settings,
2727
XslPolicyGetPoliciesNamesList $policyList
28-
) {
28+
) {
2929
$token = $tokenStorage->getToken();
3030
if (null !== $token && $token->getUser() instanceof UserInterface) {
3131
$this->user = $token->getUser();
@@ -75,7 +75,8 @@ public function buildForm(FormBuilderInterface $builder, array $options)
7575
1 => 1,
7676
2 => 2,
7777
3 => 3,
78-
4 => 4, '5 (most verbose)' => 5,
78+
4 => 4,
79+
'5 (most verbose)' => 5,
7980
],
8081
'placeholder' => false,
8182
'required' => false,

src/PaymentBundle/Lib/IpToCountry.php

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,6 @@
22

33
namespace PaymentBundle\Lib;
44

5-
use BrightNucleus\GeoLite2Country\Database;
65
use GeoIp2\Database\Reader;
76
use GeoIp2\Exception\AddressNotFoundException;
87

src/UserBundle/Form/Type/SettingsFormType.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ public function __construct(
2626
EntityManagerInterface $em,
2727
SettingsManager $settings,
2828
XslPolicyGetPoliciesNamesList $policyList
29-
) {
29+
) {
3030
$token = $tokenStorage->getToken();
3131
if (null !== $token && $token->getUser() instanceof UserInterface) {
3232
$this->user = $token->getUser();

src/UserBundle/Lib/ApiKey/ApiKeyManager.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ public function __construct(
2020
RequestStack $requestStack,
2121
TokenGeneratorInterface $tokenGenerator,
2222
EncoderFactoryInterface $encoderFactory
23-
) {
23+
) {
2424
$this->em = $em;
2525
$this->requestStack = $requestStack;
2626
$this->tokenGenerator = $tokenGenerator;

0 commit comments

Comments
 (0)