Skip to content

Commit

Permalink
[v5] Drop php <8.0 support
Browse files Browse the repository at this point in the history
  • Loading branch information
samsonasik committed Sep 7, 2024
1 parent f33bc58 commit 8fb7e67
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 24 deletions.
6 changes: 3 additions & 3 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
}
],
"require": {
"php": "^7.3|~8.0",
"php": "^8.1",
"laminas/laminas-json": "^2.5 || ^3.0",
"laminas/laminas-mvc": "^3.0",
"laminas/laminas-session": "^2.8.4"
Expand All @@ -30,9 +30,9 @@
"laminas/laminas-mvc-plugin-flashmessenger": "^1.0",
"laminas/laminas-router": "^3.0",
"laminas/laminas-serializer": "^2.5",
"laminas/laminas-test": "^4.0",
"laminas/laminas-test": "^4.10",
"phpspec/prophecy-phpunit": "^2.0",
"phpunit/phpunit": "^9.4",
"phpunit/phpunit": "^10.4",
"rector/rector": "dev-main"
},
"conflict": {
Expand Down
10 changes: 3 additions & 7 deletions rector.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@

use Rector\Config\RectorConfig;
use Rector\CodeQuality\Rector\Array_\CallableThisArrayToAnonymousFunctionRector;
use Rector\Php81\Rector\Array_\FirstClassCallableRector;

return RectorConfig::configure()
->withPreparedSets(
Expand All @@ -13,16 +14,11 @@
true, // naming
)
->withPhpSets(
false,
false,
false,
false,
false,
true, // php73
php81: true
)
->withPaths([__DIR__ . '/config', __DIR__ . '/src', __DIR__ . '/test'])
->withRootFiles()
->withImportNames()
->withSkip([
CallableThisArrayToAnonymousFunctionRector::class,
FirstClassCallableRector::class
]);
2 changes: 1 addition & 1 deletion src/Collector/SessionCollector.php
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ public function getPriority()
*/
public function collect(MvcEvent $mvcEvent)
{
$this->data['san-session'] = $this->data['san-session'] ?? [];
$this->data['san-session'] ??= [];
}

/**
Expand Down
14 changes: 1 addition & 13 deletions src/Controller/SessionToolbarController.php
Original file line number Diff line number Diff line change
Expand Up @@ -35,23 +35,11 @@
*/
final class SessionToolbarController extends AbstractActionController
{
/**
* @var RendererInterface
*/
private $viewRenderer;

/**
* @var SessionManagerInterface
*/
private $sessionManager;

/**
* Construct.
*/
public function __construct(RendererInterface $viewRenderer, SessionManagerInterface $sessionManager)
public function __construct(private readonly RendererInterface $viewRenderer, private readonly SessionManagerInterface $sessionManager)
{
$this->viewRenderer = $viewRenderer;
$this->sessionManager = $sessionManager;
}

/**
Expand Down

0 comments on commit 8fb7e67

Please sign in to comment.