Skip to content

Commit 0cce3c2

Browse files
authored
Merge pull request #180 from php-school/strict-types
Strict types
2 parents bbd9849 + 94e0d7a commit 0cce3c2

File tree

128 files changed

+264
-12
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

128 files changed

+264
-12
lines changed

app/config.php

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,7 @@
11
<?php
22

3+
declare(strict_types=1);
4+
35
use Colors\Color;
46
use function DI\create;
57
use function DI\factory;
@@ -241,14 +243,14 @@
241243
->withInsertion(new Insertion(Insertion::TYPE_BEFORE, 'ini_set("display_errors", 1);'))
242244
->withInsertion(new Insertion(Insertion::TYPE_BEFORE, 'error_reporting(E_ALL);'))
243245
->withInsertion(new Insertion(Insertion ::TYPE_BEFORE, 'date_default_timezone_set("Europe/London");'));
244-
246+
245247
return new CodePatcher($c->get(Parser::class), new Standard, $patch);
246248
},
247249
FakerGenerator::class => function () {
248250
return FakerFactory::create();
249251
},
250252
RequestRenderer::class => create(),
251-
253+
252254
Terminal::class => factory([TerminalFactory::class, 'fromSystem']),
253255
'menu' => factory(MenuFactory::class),
254256
MenuFactory::class => create(),

src/Application.php

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,7 @@
11
<?php
22

3+
declare(strict_types=1);
4+
35
namespace PhpSchool\PhpWorkshop;
46

57
use DI\ContainerBuilder;

src/Check/CheckInterface.php

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,7 @@
11
<?php
22

3+
declare(strict_types=1);
4+
35
namespace PhpSchool\PhpWorkshop\Check;
46

57
/**

src/Check/CheckRepository.php

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,7 @@
11
<?php
22

3+
declare(strict_types=1);
4+
35
namespace PhpSchool\PhpWorkshop\Check;
46

57
use PhpSchool\PhpWorkshop\Exception\InvalidArgumentException;

src/Check/CodeParseCheck.php

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,7 @@
11
<?php
22

3+
declare(strict_types=1);
4+
35
namespace PhpSchool\PhpWorkshop\Check;
46

57
use PhpParser\Error;

src/Check/ComposerCheck.php

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,7 @@
11
<?php
22

3+
declare(strict_types=1);
4+
35
namespace PhpSchool\PhpWorkshop\Check;
46

57
use PhpSchool\PhpWorkshop\ComposerUtil\LockFileParser;

src/Check/DatabaseCheck.php

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,7 @@
11
<?php
22

3+
declare(strict_types=1);
4+
35
namespace PhpSchool\PhpWorkshop\Check;
46

57
use PDO;

src/Check/FileExistsCheck.php

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,7 @@
11
<?php
22

3+
declare(strict_types=1);
4+
35
namespace PhpSchool\PhpWorkshop\Check;
46

57
use PhpSchool\PhpWorkshop\Exercise\ExerciseInterface;

src/Check/FunctionRequirementsCheck.php

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,7 @@
11
<?php
22

3+
declare(strict_types=1);
4+
35
namespace PhpSchool\PhpWorkshop\Check;
46

57
use PhpParser\Error;

src/Check/ListenableCheckInterface.php

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,7 @@
11
<?php
22

3+
declare(strict_types=1);
4+
35
namespace PhpSchool\PhpWorkshop\Check;
46

57
use PhpSchool\PhpWorkshop\Event\EventDispatcher;

0 commit comments

Comments
 (0)