Skip to content

Commit 802f60f

Browse files
committed
Psalm level 8
1 parent ade1a7a commit 802f60f

File tree

9 files changed

+24
-2
lines changed

9 files changed

+24
-2
lines changed

composer.json

+3-2
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,9 @@
22
"name": "xdebug/xdebug.org",
33
"type": "project",
44
"require-dev": {
5-
"vimeo/psalm": "^3.5",
6-
"zetacomponents/feed": "^1.4"
5+
"vimeo/psalm": "^5.23",
6+
"zetacomponents/feed": "^1.4",
7+
"composer/xdebug-handler": "^3.0"
78
},
89
"autoload": {
910
"files": [

psalm.xml

+1
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
<psalm
33
totallyTyped="false"
44
resolveFromConfigFile="true"
5+
errorLevel="8"
56
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
67
xmlns="https://getpsalm.org/schema/config"
78
xsi:schemaLocation="https://getpsalm.org/schema/config vendor/vimeo/psalm/config.xsd"

src/Model/Country.php

+2
Original file line numberDiff line numberDiff line change
@@ -291,6 +291,7 @@ public function isVatNumberRequired() : bool
291291
};
292292
}
293293

294+
/** @psalm-mutation-free */
294295
public function isVatChargable() : bool
295296
{
296297
return match($this) {
@@ -300,6 +301,7 @@ public function isVatChargable() : bool
300301
};
301302
}
302303

304+
/** @psalm-mutation-free */
303305
public function getVATPercentage()
304306
{
305307
return $this->isVatChargable() ? 0.20 : 0;

views/funding/index.php

+3
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,7 @@
11
<?php
2+
/**
3+
* @psalm-scope-this XdebugDotOrg\Model\FundingProjectsList
4+
*/
25
XdebugDotOrg\Controller\TemplateController::setTitle('Xdebug: Projects');
36
?>
47

views/funding/project.php

+3
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,7 @@
11
<?php
2+
/**
3+
* @psalm-scope-this XdebugDotOrg\Model\FundingProject
4+
*/
25
XdebugDotOrg\Controller\TemplateController::setTitle('Xdebug: Project: ' . $this->title);
36
?>
47

views/stripe/cancelled.php

+3
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,7 @@
11
<?php
2+
/**
3+
* @psalm-scope-this XdebugDotOrg\Model\StripeSession
4+
*/
25
XdebugDotOrg\Controller\TemplateController::setTitle('Xdebug: Support — Payment Cancelled');
36
?>
47

views/stripe/index.php

+3
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,7 @@
11
<?php
2+
/**
3+
* @psalm-scope-this XdebugDotOrg\Model\SubscriptionData
4+
*/
25
XdebugDotOrg\Controller\TemplateController::setTitle('Xdebug: Support Sign Up');
36

47
use XdebugDotOrg\Model\Country;

views/stripe/thanks-funding.php

+3
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,7 @@
11
<?php
2+
/**
3+
* @psalm-scope-this XdebugDotOrg\Model\StripeSession
4+
*/
25
XdebugDotOrg\Controller\TemplateController::setTitle('Xdebug: Support — Thanks');
36
?>
47

views/stripe/thanks.php

+3
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,7 @@
11
<?php
2+
/**
3+
* @psalm-scope-this XdebugDotOrg\Model\StripeSession
4+
*/
25
XdebugDotOrg\Controller\TemplateController::setTitle('Xdebug: Support — Thanks');
36
?>
47

0 commit comments

Comments
 (0)