Skip to content

Commit 205a240

Browse files
committed
TASK: Adjust phpstan config to apply level 8 rules to the Flow/Session context and reduce breakiness
1 parent d968f3d commit 205a240

File tree

2 files changed

+4
-3
lines changed

2 files changed

+4
-3
lines changed

Neos.Flow/Classes/Session/Session.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -300,12 +300,12 @@ public function renewId(): string
300300
if (!$this->sessionMetaData) {
301301
throw new \Exception('Missing session metadata');
302302
}
303-
if (!$this->sessionCookie) {
304-
throw new \Exception('Missing session cookie');
305-
}
306303
if ($this->remote === true) {
307304
throw new Exception\OperationNotSupportedException(sprintf('Tried to renew the session identifier on a remote session (%s).', $this->sessionMetaData->sessionIdentifier->value), 1354034230);
308305
}
306+
if (!$this->sessionCookie) {
307+
throw new \Exception('Missing session cookie');
308+
}
309309

310310
$this->sessionMetaDataStore->remove($this->sessionMetaData);
311311
$this->sessionMetaData = $this->sessionMetaData->withNewSessionIdentifier();

phpstan.neon.dist

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
parameters:
22
level: 8
33
paths:
4+
- Neos.Flow/Classes/Session
45
- Neos.Flow/Classes/SignalSlot
56
- Neos.Flow/Classes/Utility
67
- Neos.Flow/Classes/Validation

0 commit comments

Comments
 (0)