diff --git a/composer.json b/composer.json index 0c9ec0926..a1729917d 100644 --- a/composer.json +++ b/composer.json @@ -4,5 +4,8 @@ "chillerlan/php-qrcode": "^3.3", "mervick/material-design-icons": "^2.2", "j4mie/idiorm": "^1.5" + }, + "require-dev": { + "phpstan/phpstan": "^0.12.99" } } diff --git a/composer.lock b/composer.lock index 40f171ada..616b75b74 100644 --- a/composer.lock +++ b/composer.lock @@ -4,7 +4,7 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "This file is @generated automatically" ], - "content-hash": "e7f23b092328c903b06c8ae31bf13781", + "content-hash": "76e40cf59f811ee42d14ac41159c570a", "packages": [ { "name": "beberlei/assert", @@ -592,7 +592,72 @@ "time": "2020-10-28T17:51:34+00:00" } ], - "packages-dev": [], + "packages-dev": [ + { + "name": "phpstan/phpstan", + "version": "0.12.99", + "source": { + "type": "git", + "url": "https://github.com/phpstan/phpstan.git", + "reference": "b4d40f1d759942f523be267a1bab6884f46ca3f7" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/phpstan/phpstan/zipball/b4d40f1d759942f523be267a1bab6884f46ca3f7", + "reference": "b4d40f1d759942f523be267a1bab6884f46ca3f7", + "shasum": "" + }, + "require": { + "php": "^7.1|^8.0" + }, + "conflict": { + "phpstan/phpstan-shim": "*" + }, + "bin": [ + "phpstan", + "phpstan.phar" + ], + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "0.12-dev" + } + }, + "autoload": { + "files": [ + "bootstrap.php" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "description": "PHPStan - PHP Static Analysis Tool", + "support": { + "issues": "https://github.com/phpstan/phpstan/issues", + "source": "https://github.com/phpstan/phpstan/tree/0.12.99" + }, + "funding": [ + { + "url": "https://github.com/ondrejmirtes", + "type": "github" + }, + { + "url": "https://github.com/phpstan", + "type": "github" + }, + { + "url": "https://www.patreon.com/phpstan", + "type": "patreon" + }, + { + "url": "https://tidelift.com/funding/github/packagist/phpstan/phpstan", + "type": "tidelift" + } + ], + "time": "2021-09-12T20:09:55+00:00" + } + ], "aliases": [], "minimum-stability": "stable", "stability-flags": [], diff --git a/vendor/bin/phpstan b/vendor/bin/phpstan new file mode 120000 index 000000000..959384f7f --- /dev/null +++ b/vendor/bin/phpstan @@ -0,0 +1 @@ +../phpstan/phpstan/phpstan \ No newline at end of file diff --git a/vendor/bin/phpstan.phar b/vendor/bin/phpstan.phar new file mode 120000 index 000000000..502769bef --- /dev/null +++ b/vendor/bin/phpstan.phar @@ -0,0 +1 @@ +../phpstan/phpstan/phpstan.phar \ No newline at end of file diff --git a/vendor/composer/InstalledVersions.php b/vendor/composer/InstalledVersions.php index e17d3b0a7..7aa64aca4 100644 --- a/vendor/composer/InstalledVersions.php +++ b/vendor/composer/InstalledVersions.php @@ -30,7 +30,7 @@ private static $installed = array ( 'aliases' => array ( ), - 'reference' => 'f96abd2b52b9de5eac3651594ca32c6a4023c3e3', + 'reference' => '2a5c2be6cdd9ba9217a0661805b62aeec1de90c3', 'dev-requirement' => true, 'name' => '__root__', ), @@ -43,7 +43,7 @@ private static $installed = array ( 'aliases' => array ( ), - 'reference' => 'f96abd2b52b9de5eac3651594ca32c6a4023c3e3', + 'reference' => '2a5c2be6cdd9ba9217a0661805b62aeec1de90c3', 'dev-requirement' => false, ), 'beberlei/assert' => @@ -106,6 +106,16 @@ private static $installed = array ( 'reference' => 'f34c2b11eb9d2c9318e13540a1dbc2a3afbd939c', 'dev-requirement' => false, ), + 'phpstan/phpstan' => + array ( + 'pretty_version' => '0.12.99', + 'version' => '0.12.99.0', + 'aliases' => + array ( + ), + 'reference' => 'b4d40f1d759942f523be267a1bab6884f46ca3f7', + 'dev-requirement' => true, + ), 'spomky-labs/otphp' => array ( 'pretty_version' => 'v10.0.1', diff --git a/vendor/composer/autoload_files.php b/vendor/composer/autoload_files.php index a2686669c..636fe7c0f 100644 --- a/vendor/composer/autoload_files.php +++ b/vendor/composer/autoload_files.php @@ -6,6 +6,7 @@ $vendorDir = dirname(dirname(__FILE__)); $baseDir = dirname($vendorDir); return array( + '9b38cf48e83f5d8f60375221cd213eee' => $vendorDir . '/phpstan/phpstan/bootstrap.php', 'a4ecaeafb8cfb009ad0e052c90355e98' => $vendorDir . '/beberlei/assert/lib/Assert/functions.php', '51fcf4e06c07cc00c920b44bcd900e7a' => $vendorDir . '/thecodingmachine/safe/deprecated/apc.php', '47f619d9197b36cf5ab70738d7743fe2' => $vendorDir . '/thecodingmachine/safe/deprecated/libevent.php', diff --git a/vendor/composer/autoload_static.php b/vendor/composer/autoload_static.php index 6f1c238b1..d1b8ceed0 100644 --- a/vendor/composer/autoload_static.php +++ b/vendor/composer/autoload_static.php @@ -7,6 +7,7 @@ namespace Composer\Autoload; class ComposerStaticInit19fc2ff1c0f9a92279c7979386bb2056 { public static $files = array ( + '9b38cf48e83f5d8f60375221cd213eee' => __DIR__ . '/..' . '/phpstan/phpstan/bootstrap.php', 'a4ecaeafb8cfb009ad0e052c90355e98' => __DIR__ . '/..' . '/beberlei/assert/lib/Assert/functions.php', '51fcf4e06c07cc00c920b44bcd900e7a' => __DIR__ . '/..' . '/thecodingmachine/safe/deprecated/apc.php', '47f619d9197b36cf5ab70738d7743fe2' => __DIR__ . '/..' . '/thecodingmachine/safe/deprecated/libevent.php', diff --git a/vendor/composer/installed.json b/vendor/composer/installed.json index 7de696894..e06a40433 100644 --- a/vendor/composer/installed.json +++ b/vendor/composer/installed.json @@ -389,6 +389,73 @@ }, "install-path": "../paragonie/constant_time_encoding" }, + { + "name": "phpstan/phpstan", + "version": "0.12.99", + "version_normalized": "0.12.99.0", + "source": { + "type": "git", + "url": "https://github.com/phpstan/phpstan.git", + "reference": "b4d40f1d759942f523be267a1bab6884f46ca3f7" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/phpstan/phpstan/zipball/b4d40f1d759942f523be267a1bab6884f46ca3f7", + "reference": "b4d40f1d759942f523be267a1bab6884f46ca3f7", + "shasum": "" + }, + "require": { + "php": "^7.1|^8.0" + }, + "conflict": { + "phpstan/phpstan-shim": "*" + }, + "time": "2021-09-12T20:09:55+00:00", + "bin": [ + "phpstan", + "phpstan.phar" + ], + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "0.12-dev" + } + }, + "installation-source": "dist", + "autoload": { + "files": [ + "bootstrap.php" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "description": "PHPStan - PHP Static Analysis Tool", + "support": { + "issues": "https://github.com/phpstan/phpstan/issues", + "source": "https://github.com/phpstan/phpstan/tree/0.12.99" + }, + "funding": [ + { + "url": "https://github.com/ondrejmirtes", + "type": "github" + }, + { + "url": "https://github.com/phpstan", + "type": "github" + }, + { + "url": "https://www.patreon.com/phpstan", + "type": "patreon" + }, + { + "url": "https://tidelift.com/funding/github/packagist/phpstan/phpstan", + "type": "tidelift" + } + ], + "install-path": "../phpstan/phpstan" + }, { "name": "spomky-labs/otphp", "version": "v10.0.1", @@ -611,5 +678,7 @@ } ], "dev": true, - "dev-package-names": [] + "dev-package-names": [ + "phpstan/phpstan" + ] } diff --git a/vendor/composer/installed.php b/vendor/composer/installed.php index 59d40508a..17ae71708 100644 --- a/vendor/composer/installed.php +++ b/vendor/composer/installed.php @@ -6,7 +6,7 @@ 'aliases' => array ( ), - 'reference' => 'f96abd2b52b9de5eac3651594ca32c6a4023c3e3', + 'reference' => '2a5c2be6cdd9ba9217a0661805b62aeec1de90c3', 'dev-requirement' => true, 'name' => '__root__', ), @@ -19,7 +19,7 @@ 'aliases' => array ( ), - 'reference' => 'f96abd2b52b9de5eac3651594ca32c6a4023c3e3', + 'reference' => '2a5c2be6cdd9ba9217a0661805b62aeec1de90c3', 'dev-requirement' => false, ), 'beberlei/assert' => @@ -82,6 +82,16 @@ 'reference' => 'f34c2b11eb9d2c9318e13540a1dbc2a3afbd939c', 'dev-requirement' => false, ), + 'phpstan/phpstan' => + array ( + 'pretty_version' => '0.12.99', + 'version' => '0.12.99.0', + 'aliases' => + array ( + ), + 'reference' => 'b4d40f1d759942f523be267a1bab6884f46ca3f7', + 'dev-requirement' => true, + ), 'spomky-labs/otphp' => array ( 'pretty_version' => 'v10.0.1', diff --git a/vendor/phpstan/phpstan/.gitattributes b/vendor/phpstan/phpstan/.gitattributes new file mode 100644 index 000000000..658b92eeb --- /dev/null +++ b/vendor/phpstan/phpstan/.gitattributes @@ -0,0 +1,11 @@ +/.github export-ignore +/BACKERS.md export-ignore +/CODE_OF_CONDUCT.md export-ignore +/docker export-ignore +/e2e export-ignore +/issue-bot export-ignore +/playground-api export-ignore +/playground-runner export-ignore +/.travis.yml export-ignore +/website export-ignore +website/* linguist-vendored diff --git a/vendor/phpstan/phpstan/.gitignore b/vendor/phpstan/phpstan/.gitignore new file mode 100644 index 000000000..020e4b465 --- /dev/null +++ b/vendor/phpstan/phpstan/.gitignore @@ -0,0 +1,9 @@ +/build/phpstan-generated.neon +/composer.lock +/conf/config.local.yml +/e2e/composer.lock +/e2e/vendor +/vendor +/.idea +/tests/tmp +/tests/.phpunit.result.cache diff --git a/vendor/phpstan/phpstan/LICENSE b/vendor/phpstan/phpstan/LICENSE new file mode 100644 index 000000000..7c0f2b7b6 --- /dev/null +++ b/vendor/phpstan/phpstan/LICENSE @@ -0,0 +1,21 @@ +MIT License + +Copyright (c) 2016 Ondřej Mirtes + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/vendor/phpstan/phpstan/README.md b/vendor/phpstan/phpstan/README.md new file mode 100644 index 000000000..b31560d28 --- /dev/null +++ b/vendor/phpstan/phpstan/README.md @@ -0,0 +1,91 @@ +

PHPStan - PHP Static Analysis Tool

+ +

+ PHPStan +

+ +

+ Build Status + Latest Stable Version + Total Downloads + License + PHPStan Enabled +

+ +------ + +PHPStan focuses on finding errors in your code without actually running it. It catches whole classes of bugs +even before you write tests for the code. It moves PHP closer to compiled languages in the sense that the correctness of each line of the code +can be checked before you run the actual line. + +**[Read more about PHPStan in an introductory article »](https://phpstan.org/blog/find-bugs-in-your-code-without-writing-tests)** + +**[Try out PHPStan on the on-line playground! »](https://phpstan.org/)** + +## Sponsors + +TheCodingMachine +    +Private Packagist +
+Musement +    +Blackfire.io +
+Intracto +    +TicketSwap +
+ShipMonk +    +Togetter +
+RightCapital +    +ContentKing +
+ZOL +    +Stepan Kocourek +
+Shopware +    +Craft CMS + +[**You can now sponsor my open-source work on PHPStan through GitHub Sponsors.**](https://github.com/sponsors/ondrejmirtes) + +Does GitHub already have your 💳? Do you use PHPStan to find 🐛 before they reach production? [Send a couple of 💸 a month my way too.](https://github.com/sponsors/ondrejmirtes) Thank you! + +One-time donations [through PayPal](https://paypal.me/phpstan) are also accepted. To request an invoice, [contact me](mailto:ondrej@mirtes.cz) through e-mail. + +## Documentation + +All the documentation lives on the [phpstan.org website](https://phpstan.org/): + +* [Getting Started & User Guide](https://phpstan.org/user-guide/getting-started) +* [Config Reference](https://phpstan.org/config-reference) +* [PHPDocs Basics](https://phpstan.org/writing-php-code/phpdocs-basics) & [PHPDoc Types](https://phpstan.org/writing-php-code/phpdoc-types) +* [Extension Library](https://phpstan.org/user-guide/extension-library) +* [Developing Extensions](https://phpstan.org/developing-extensions/extension-types) + +## PHPStan Pro + +PHPStan Pro is a paid add-on on top of open-source PHPStan Static Analysis Tool with these premium features: + +* Web UI for browsing found errors, you can click and open your editor of choice on the offending line. +* Continuous analysis (watch mode): scans changed files in the background, refreshes the UI automatically. +* Interactive fixer: lets you choose the right fix for found errors :blush: + +Try it on PHPStan 0.12.45 or later by running it with the `--pro` option. You can create an account either by following the on-screen instructions, or by visiting [account.phpstan.com](https://account.phpstan.com/). + +After 30-day free trial period it costs 7 EUR for individuals monthly, 70 EUR for teams (up to 25 members). By paying for PHPStan Pro, you're supporting the development of open-source PHPStan. + +You can read more about it on [PHPStan's website](https://phpstan.org/blog/introducing-phpstan-pro). + +## Code of Conduct + +This project adheres to a [Contributor Code of Conduct](https://github.com/phpstan/phpstan/blob/master/CODE_OF_CONDUCT.md). By participating in this project and its community, you are expected to uphold this code. + +## Contributing + +Any contributions are welcome. PHPStan's source code open to pull requests lives at [`phpstan/phpstan-src`](https://github.com/phpstan/phpstan-src). diff --git a/vendor/phpstan/phpstan/bootstrap.php b/vendor/phpstan/phpstan/bootstrap.php new file mode 100644 index 000000000..e8b943167 --- /dev/null +++ b/vendor/phpstan/phpstan/bootstrap.php @@ -0,0 +1,60 @@ +loadClass($class); + + return; + } + if (strpos($class, 'PHPStan\\') !== 0 || strpos($class, 'PHPStan\\PhpDocParser\\') === 0) { + return; + } + + if (!in_array('phar', stream_get_wrappers(), true)) { + throw new \Exception('Phar wrapper is not registered. Please review your php.ini settings.'); + } + + $filename = str_replace('\\', DIRECTORY_SEPARATOR, $class); + if (strpos($class, 'PHPStan\\BetterReflection\\') === 0) { + $filename = substr($filename, strlen('PHPStan\\BetterReflection\\')); + $filepath = 'phar://' . __DIR__ . '/phpstan.phar/vendor/ondrejmirtes/better-reflection/src/' . $filename . '.php'; + } else { + $filename = substr($filename, strlen('PHPStan\\')); + $filepath = 'phar://' . __DIR__ . '/phpstan.phar/src/' . $filename . '.php'; + } + + if (!file_exists($filepath)) { + return; + } + + require $filepath; + } +} + +spl_autoload_register([PharAutoloader::class, 'loadClass']); diff --git a/vendor/phpstan/phpstan/composer.json b/vendor/phpstan/phpstan/composer.json new file mode 100644 index 000000000..2e1182949 --- /dev/null +++ b/vendor/phpstan/phpstan/composer.json @@ -0,0 +1,23 @@ +{ + "name": "phpstan/phpstan", + "description": "PHPStan - PHP Static Analysis Tool", + "license": ["MIT"], + "require": { + "php": "^7.1|^8.0" + }, + "conflict": { + "phpstan/phpstan-shim": "*" + }, + "bin": [ + "phpstan", + "phpstan.phar" + ], + "extra": { + "branch-alias": { + "dev-master": "0.12-dev" + } + }, + "autoload": { + "files": ["bootstrap.php"] + } +} diff --git a/vendor/phpstan/phpstan/conf/bleedingEdge.neon b/vendor/phpstan/phpstan/conf/bleedingEdge.neon new file mode 100644 index 000000000..01fee972d --- /dev/null +++ b/vendor/phpstan/phpstan/conf/bleedingEdge.neon @@ -0,0 +1,2 @@ +includes: + - phar://phpstan.phar/conf/bleedingEdge.neon diff --git a/vendor/phpstan/phpstan/phpstan b/vendor/phpstan/phpstan/phpstan new file mode 100644 index 000000000..7a08ef485 --- /dev/null +++ b/vendor/phpstan/phpstan/phpstan @@ -0,0 +1,8 @@ +#!/usr/bin/env php +