Skip to content

Commit

Permalink
fix psalm
Browse files Browse the repository at this point in the history
  • Loading branch information
RobinDev committed Feb 27, 2024
1 parent d7ca620 commit 88c33c9
Show file tree
Hide file tree
Showing 4 changed files with 11 additions and 11 deletions.
2 changes: 1 addition & 1 deletion packages/docs/content/homepage.md
Expand Up @@ -75,7 +75,7 @@ Unzip it on a classic Apache/PHP server and play.
<p>Pushword run on a classic up to date <strong>PHP</strong> environnement (and Composer). You have this on your machine or just a cheap shared host ? So you are able to install it in a few seconds.</p>
<p><a href="/installation">Learn more about requirements and installation.</a></p>
<p>By default, it works without dirty work. It looks <strong>so simple</strong>. But don't be wrong, you can do amazing custom thing with it !</p>
<p class="text-sm font-light text-center text-green-500"><strong style="color: rgba(16, 185, 129, var(--tw-text-opacity));">PHP 8</strong> // Symfony 6</p>
<p class="text-sm font-light text-center text-green-500"><strong style="color: rgba(16, 185, 129, var(--tw-text-opacity));">PHP 8</strong> // Symfony 7</p>
</div>
</div>
<div class="px-3 py-6 mb-6 rounded-lg dark:bg-gray-900 bg-white shadow dark:text-gray-50">
Expand Down
4 changes: 2 additions & 2 deletions packages/docs/content/installation.md
Expand Up @@ -7,10 +7,10 @@ toc: true

## Requirements

- **PHP** >=8.1
- **PHP** >=8.2
- **PHP extensions** : dom, curl, libxml, mbstring, zip, pdo, sqlite, pdo_sqlite, bcmath, soap, intl, gd, imagick, exif, iconv, fileinfo
- **Composer** (#[how to install composer](https://getcomposer.org/download/))
- **Node** (>= 16.20.2, see [nvm to easily install a node version up to date](https://github.com/nvm-sh/nvm) - only tested with v20.9.0)
- **Node** (>= 16.20.2, see [nvm to easily install a node version up to date](https://github.com/nvm-sh/nvm) - only tested with v20.11.1)
- **yarn** (#[how to install yarn](https://classic.yarnpkg.com/lang/en/docs/install/#debian-stable))

_Note_ : Node and Yarn may not be required in the near future, [thanks to asset mapper](https://symfony.com/doc/current/frontend/asset_mapper.html).
Expand Down
1 change: 1 addition & 0 deletions packages/version/src/Versionner.php
Expand Up @@ -117,6 +117,7 @@ public function getPageVersions(int|PageInterface $page): array
return [];
}

/** @var string[] */
$scandir = scandir($dir);

$versions = array_filter($scandir, static fn (string $item): bool => ! \in_array($item, ['.', '..'], true));
Expand Down
15 changes: 7 additions & 8 deletions psalm.xml.dist
@@ -1,13 +1,18 @@
<?xml version="1.0"?>
<psalm errorLevel="4" findUnusedVariablesAndParams="true" resolveFromConfigFile="true"
<psalm errorLevel="3" findUnusedVariablesAndParams="true" resolveFromConfigFile="true"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="https://getpsalm.org/schema/config"
xsi:schemaLocation="https://getpsalm.org/schema/config vendor/vimeo/psalm/config.xsd">
<plugins>
<pluginClass class="Psalm\SymfonyPsalmPlugin\Plugin">
<containerXml>/tmp/com.github.pushword.pushword/tests/var/dev/cache/App_KernelDevDebugContainer.xml</containerXml>
</pluginClass>
<pluginClass class="Weirdan\DoctrinePsalmPlugin\Plugin" />
</plugins>
<projectFiles>
<directory name="packages/**/src" />
<ignoreFiles>
<directory name="vendor" />
</ignoreFiles>

</projectFiles>
<issueHandlers>
<MissingTemplateParam>
Expand Down Expand Up @@ -42,10 +47,4 @@
</errorLevel>
</PossiblyUndefinedMethod>
</issueHandlers>
<plugins>
<pluginClass class="Psalm\SymfonyPsalmPlugin\Plugin">
<containerXml>/tmp/com.github.pushword.pushword/tests/var/dev/cache/App_KernelDevDebugContainer.xml</containerXml>
</pluginClass>
<pluginClass class="Weirdan\DoctrinePsalmPlugin\Plugin" />
</plugins>
</psalm>

0 comments on commit 88c33c9

Please sign in to comment.