diff --git a/.github/workflows/php-coding-standards.yml b/.github/workflows/php-coding-standards.yml new file mode 100644 index 00000000..8b03484d --- /dev/null +++ b/.github/workflows/php-coding-standards.yml @@ -0,0 +1,55 @@ +name: PHP coding standards + +on: + push: + branches: [ master ] + pull_request: + branches: [ master ] + +jobs: + build: + + runs-on: ubuntu-latest + + steps: + - name: Setup PHP8.1 + uses: shivammathur/setup-php@v2 + with: + php-version: '8.1' + + - uses: actions/checkout@v2 + + - name: Validate composer.json and composer.lock + run: composer validate --strict + + - name: Cache Composer packages + id: composer-cache + uses: actions/cache@v2 + with: + path: vendor + key: ${{ runner.os }}-php-${{ hashFiles('**/composer.lock') }} + restore-keys: | + ${{ runner.os }}-php- + + - name: Install dependencies + if: steps.composer-cache.outputs.cache-hit != 'true' + run: composer install --prefer-dist --no-progress + + - name: Composer dump-autoload to load all files + run: composer dump-autoload + + - name: Run codefixer + run: composer run-script php-cs-fixer + + - name: Check if code are already generated + uses: tj-actions/verify-changed-files@v8.8 + id: verify-changed-files + with: + files: | + src + tests + + - name: Run step only when files change. + if: steps.verify-changed-files.outputs.files_changed == 'true' + run: | + core.setFailed('Inconsistent coding standards. Please run `composer run-script php-cs-fixer` locally and commit style.') \ No newline at end of file diff --git a/.php-cs-fixer.dist.php b/.php-cs-fixer.dist.php new file mode 100644 index 00000000..3ba99600 --- /dev/null +++ b/.php-cs-fixer.dist.php @@ -0,0 +1,10 @@ +in([__DIR__ . '/src', __DIR__ . '/tests']); + +return (new PhpCsFixer\Config()) + ->setRules([ + '@PSR12' => true, + ]) + ->setFinder($finder); \ No newline at end of file diff --git a/CHANGELOG.md b/CHANGELOG.md index 3f7acfad..defc8e3f 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -10,6 +10,7 @@ and this project adheres to [Semantic Versioning](http://semver.org/). ### Added - Retrieve, create and delete SongArrangement comments ([PR187](https://github.com/5pm-HDH/churchtools-api/pull/187)) - Get GroupTypes ([PR188](https://github.com/5pm-HDH/churchtools-api/pull/188)) +- PHP coding standard ([PR193](https://github.com/5pm-HDH/churchtools-api/pull/193)) ### Changed diff --git a/composer.json b/composer.json index 7a903b24..edff98f6 100644 --- a/composer.json +++ b/composer.json @@ -20,7 +20,8 @@ }, "require-dev": { "phpunit/phpunit": "9.5.5", - "phpstan/phpstan": "^1.10" + "phpstan/phpstan": "^1.10", + "friendsofphp/php-cs-fixer": "^3.46" }, "license": "MIT", "authors": [ @@ -37,6 +38,7 @@ "test-coverage-w": "vendor\\bin\\phpunit.bat --coverage-html .phpunit.cache/coverage-report", "phpstan": "./vendor/bin/phpstan analyse -c phpstan.neon --memory-limit 1G", "phpstan-w": "vendor\\bin\\phpstan.bat analyse -c phpstan.neon --memory-limit 1G", + "php-cs-fixer": "vendor/bin/php-cs-fixer fix", "docs-generator": "php docs/src/DocGenerator.php" } } diff --git a/composer.lock b/composer.lock index 8ae35563..9a181cfe 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": "ee00a3ba80b699e048fdc4396a7aedb7", + "content-hash": "916bb3e170c87c149fe50e30dab3556f", "packages": [ { "name": "doctrine/cache", @@ -854,6 +854,224 @@ } ], "packages-dev": [ + { + "name": "composer/pcre", + "version": "3.1.1", + "source": { + "type": "git", + "url": "https://github.com/composer/pcre.git", + "reference": "00104306927c7a0919b4ced2aaa6782c1e61a3c9" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/composer/pcre/zipball/00104306927c7a0919b4ced2aaa6782c1e61a3c9", + "reference": "00104306927c7a0919b4ced2aaa6782c1e61a3c9", + "shasum": "" + }, + "require": { + "php": "^7.4 || ^8.0" + }, + "require-dev": { + "phpstan/phpstan": "^1.3", + "phpstan/phpstan-strict-rules": "^1.1", + "symfony/phpunit-bridge": "^5" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-main": "3.x-dev" + } + }, + "autoload": { + "psr-4": { + "Composer\\Pcre\\": "src" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Jordi Boggiano", + "email": "j.boggiano@seld.be", + "homepage": "http://seld.be" + } + ], + "description": "PCRE wrapping library that offers type-safe preg_* replacements.", + "keywords": [ + "PCRE", + "preg", + "regex", + "regular expression" + ], + "support": { + "issues": "https://github.com/composer/pcre/issues", + "source": "https://github.com/composer/pcre/tree/3.1.1" + }, + "funding": [ + { + "url": "https://packagist.com", + "type": "custom" + }, + { + "url": "https://github.com/composer", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/composer/composer", + "type": "tidelift" + } + ], + "time": "2023-10-11T07:11:09+00:00" + }, + { + "name": "composer/semver", + "version": "3.4.0", + "source": { + "type": "git", + "url": "https://github.com/composer/semver.git", + "reference": "35e8d0af4486141bc745f23a29cc2091eb624a32" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/composer/semver/zipball/35e8d0af4486141bc745f23a29cc2091eb624a32", + "reference": "35e8d0af4486141bc745f23a29cc2091eb624a32", + "shasum": "" + }, + "require": { + "php": "^5.3.2 || ^7.0 || ^8.0" + }, + "require-dev": { + "phpstan/phpstan": "^1.4", + "symfony/phpunit-bridge": "^4.2 || ^5" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-main": "3.x-dev" + } + }, + "autoload": { + "psr-4": { + "Composer\\Semver\\": "src" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Nils Adermann", + "email": "naderman@naderman.de", + "homepage": "http://www.naderman.de" + }, + { + "name": "Jordi Boggiano", + "email": "j.boggiano@seld.be", + "homepage": "http://seld.be" + }, + { + "name": "Rob Bast", + "email": "rob.bast@gmail.com", + "homepage": "http://robbast.nl" + } + ], + "description": "Semver library that offers utilities, version constraint parsing and validation.", + "keywords": [ + "semantic", + "semver", + "validation", + "versioning" + ], + "support": { + "irc": "ircs://irc.libera.chat:6697/composer", + "issues": "https://github.com/composer/semver/issues", + "source": "https://github.com/composer/semver/tree/3.4.0" + }, + "funding": [ + { + "url": "https://packagist.com", + "type": "custom" + }, + { + "url": "https://github.com/composer", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/composer/composer", + "type": "tidelift" + } + ], + "time": "2023-08-31T09:50:34+00:00" + }, + { + "name": "composer/xdebug-handler", + "version": "3.0.3", + "source": { + "type": "git", + "url": "https://github.com/composer/xdebug-handler.git", + "reference": "ced299686f41dce890debac69273b47ffe98a40c" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/composer/xdebug-handler/zipball/ced299686f41dce890debac69273b47ffe98a40c", + "reference": "ced299686f41dce890debac69273b47ffe98a40c", + "shasum": "" + }, + "require": { + "composer/pcre": "^1 || ^2 || ^3", + "php": "^7.2.5 || ^8.0", + "psr/log": "^1 || ^2 || ^3" + }, + "require-dev": { + "phpstan/phpstan": "^1.0", + "phpstan/phpstan-strict-rules": "^1.1", + "symfony/phpunit-bridge": "^6.0" + }, + "type": "library", + "autoload": { + "psr-4": { + "Composer\\XdebugHandler\\": "src" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "John Stevenson", + "email": "john-stevenson@blueyonder.co.uk" + } + ], + "description": "Restarts a process without Xdebug.", + "keywords": [ + "Xdebug", + "performance" + ], + "support": { + "irc": "irc://irc.freenode.org/composer", + "issues": "https://github.com/composer/xdebug-handler/issues", + "source": "https://github.com/composer/xdebug-handler/tree/3.0.3" + }, + "funding": [ + { + "url": "https://packagist.com", + "type": "custom" + }, + { + "url": "https://github.com/composer", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/composer/composer", + "type": "tidelift" + } + ], + "time": "2022-02-25T21:32:43+00:00" + }, { "name": "doctrine/deprecations", "version": "v1.1.1", @@ -971,6 +1189,97 @@ ], "time": "2022-12-30T00:15:36+00:00" }, + { + "name": "friendsofphp/php-cs-fixer", + "version": "v3.46.0", + "source": { + "type": "git", + "url": "https://github.com/PHP-CS-Fixer/PHP-CS-Fixer.git", + "reference": "be6831c9af1740470d2a773119b9273f8ac1c3d2" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/PHP-CS-Fixer/PHP-CS-Fixer/zipball/be6831c9af1740470d2a773119b9273f8ac1c3d2", + "reference": "be6831c9af1740470d2a773119b9273f8ac1c3d2", + "shasum": "" + }, + "require": { + "composer/semver": "^3.4", + "composer/xdebug-handler": "^3.0.3", + "ext-filter": "*", + "ext-json": "*", + "ext-tokenizer": "*", + "php": "^7.4 || ^8.0", + "sebastian/diff": "^4.0 || ^5.0", + "symfony/console": "^5.4 || ^6.0 || ^7.0", + "symfony/event-dispatcher": "^5.4 || ^6.0 || ^7.0", + "symfony/filesystem": "^5.4 || ^6.0 || ^7.0", + "symfony/finder": "^5.4 || ^6.0 || ^7.0", + "symfony/options-resolver": "^5.4 || ^6.0 || ^7.0", + "symfony/polyfill-mbstring": "^1.28", + "symfony/polyfill-php80": "^1.28", + "symfony/polyfill-php81": "^1.28", + "symfony/process": "^5.4 || ^6.0 || ^7.0", + "symfony/stopwatch": "^5.4 || ^6.0 || ^7.0" + }, + "require-dev": { + "facile-it/paraunit": "^1.3 || ^2.0", + "justinrainbow/json-schema": "^5.2", + "keradus/cli-executor": "^2.1", + "mikey179/vfsstream": "^1.6.11", + "php-coveralls/php-coveralls": "^2.7", + "php-cs-fixer/accessible-object": "^1.1", + "php-cs-fixer/phpunit-constraint-isidenticalstring": "^1.4", + "php-cs-fixer/phpunit-constraint-xmlmatchesxsd": "^1.4", + "phpunit/phpunit": "^9.6 || ^10.5.5", + "symfony/yaml": "^5.4 || ^6.0 || ^7.0" + }, + "suggest": { + "ext-dom": "For handling output formats in XML", + "ext-mbstring": "For handling non-UTF8 characters." + }, + "bin": [ + "php-cs-fixer" + ], + "type": "application", + "autoload": { + "psr-4": { + "PhpCsFixer\\": "src/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Fabien Potencier", + "email": "fabien@symfony.com" + }, + { + "name": "Dariusz RumiƄski", + "email": "dariusz.ruminski@gmail.com" + } + ], + "description": "A tool to automatically fix PHP code style", + "keywords": [ + "Static code analysis", + "fixer", + "standards", + "static analysis" + ], + "support": { + "issues": "https://github.com/PHP-CS-Fixer/PHP-CS-Fixer/issues", + "source": "https://github.com/PHP-CS-Fixer/PHP-CS-Fixer/tree/v3.46.0" + }, + "funding": [ + { + "url": "https://github.com/keradus", + "type": "github" + } + ], + "time": "2024-01-03T21:38:46+00:00" + }, { "name": "myclabs/deep-copy", "version": "1.11.1", @@ -1965,106 +2274,209 @@ "time": "2021-06-05T04:49:07+00:00" }, { - "name": "sebastian/cli-parser", - "version": "1.0.1", + "name": "psr/container", + "version": "2.0.2", "source": { "type": "git", - "url": "https://github.com/sebastianbergmann/cli-parser.git", - "reference": "442e7c7e687e42adc03470c7b668bc4b2402c0b2" + "url": "https://github.com/php-fig/container.git", + "reference": "c71ecc56dfe541dbd90c5360474fbc405f8d5963" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/cli-parser/zipball/442e7c7e687e42adc03470c7b668bc4b2402c0b2", - "reference": "442e7c7e687e42adc03470c7b668bc4b2402c0b2", + "url": "https://api.github.com/repos/php-fig/container/zipball/c71ecc56dfe541dbd90c5360474fbc405f8d5963", + "reference": "c71ecc56dfe541dbd90c5360474fbc405f8d5963", "shasum": "" }, "require": { - "php": ">=7.3" - }, - "require-dev": { - "phpunit/phpunit": "^9.3" + "php": ">=7.4.0" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "1.0-dev" + "dev-master": "2.0.x-dev" } }, "autoload": { - "classmap": [ - "src/" - ] + "psr-4": { + "Psr\\Container\\": "src/" + } }, "notification-url": "https://packagist.org/downloads/", "license": [ - "BSD-3-Clause" + "MIT" ], "authors": [ { - "name": "Sebastian Bergmann", - "email": "sebastian@phpunit.de", - "role": "lead" + "name": "PHP-FIG", + "homepage": "https://www.php-fig.org/" } ], - "description": "Library for parsing CLI options", - "homepage": "https://github.com/sebastianbergmann/cli-parser", + "description": "Common Container Interface (PHP FIG PSR-11)", + "homepage": "https://github.com/php-fig/container", + "keywords": [ + "PSR-11", + "container", + "container-interface", + "container-interop", + "psr" + ], "support": { - "issues": "https://github.com/sebastianbergmann/cli-parser/issues", - "source": "https://github.com/sebastianbergmann/cli-parser/tree/1.0.1" + "issues": "https://github.com/php-fig/container/issues", + "source": "https://github.com/php-fig/container/tree/2.0.2" }, - "funding": [ - { - "url": "https://github.com/sebastianbergmann", - "type": "github" - } - ], - "time": "2020-09-28T06:08:49+00:00" + "time": "2021-11-05T16:47:00+00:00" }, { - "name": "sebastian/code-unit", - "version": "1.0.8", + "name": "psr/event-dispatcher", + "version": "1.0.0", "source": { "type": "git", - "url": "https://github.com/sebastianbergmann/code-unit.git", - "reference": "1fc9f64c0927627ef78ba436c9b17d967e68e120" + "url": "https://github.com/php-fig/event-dispatcher.git", + "reference": "dbefd12671e8a14ec7f180cab83036ed26714bb0" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/code-unit/zipball/1fc9f64c0927627ef78ba436c9b17d967e68e120", - "reference": "1fc9f64c0927627ef78ba436c9b17d967e68e120", + "url": "https://api.github.com/repos/php-fig/event-dispatcher/zipball/dbefd12671e8a14ec7f180cab83036ed26714bb0", + "reference": "dbefd12671e8a14ec7f180cab83036ed26714bb0", "shasum": "" }, "require": { - "php": ">=7.3" - }, - "require-dev": { - "phpunit/phpunit": "^9.3" + "php": ">=7.2.0" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "1.0-dev" + "dev-master": "1.0.x-dev" } }, "autoload": { - "classmap": [ - "src/" - ] + "psr-4": { + "Psr\\EventDispatcher\\": "src/" + } }, "notification-url": "https://packagist.org/downloads/", "license": [ - "BSD-3-Clause" + "MIT" ], "authors": [ { - "name": "Sebastian Bergmann", - "email": "sebastian@phpunit.de", - "role": "lead" + "name": "PHP-FIG", + "homepage": "http://www.php-fig.org/" } ], - "description": "Collection of value objects that represent the PHP code units", - "homepage": "https://github.com/sebastianbergmann/code-unit", - "support": { + "description": "Standard interfaces for event handling.", + "keywords": [ + "events", + "psr", + "psr-14" + ], + "support": { + "issues": "https://github.com/php-fig/event-dispatcher/issues", + "source": "https://github.com/php-fig/event-dispatcher/tree/1.0.0" + }, + "time": "2019-01-08T18:20:26+00:00" + }, + { + "name": "sebastian/cli-parser", + "version": "1.0.1", + "source": { + "type": "git", + "url": "https://github.com/sebastianbergmann/cli-parser.git", + "reference": "442e7c7e687e42adc03470c7b668bc4b2402c0b2" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/sebastianbergmann/cli-parser/zipball/442e7c7e687e42adc03470c7b668bc4b2402c0b2", + "reference": "442e7c7e687e42adc03470c7b668bc4b2402c0b2", + "shasum": "" + }, + "require": { + "php": ">=7.3" + }, + "require-dev": { + "phpunit/phpunit": "^9.3" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.0-dev" + } + }, + "autoload": { + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de", + "role": "lead" + } + ], + "description": "Library for parsing CLI options", + "homepage": "https://github.com/sebastianbergmann/cli-parser", + "support": { + "issues": "https://github.com/sebastianbergmann/cli-parser/issues", + "source": "https://github.com/sebastianbergmann/cli-parser/tree/1.0.1" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2020-09-28T06:08:49+00:00" + }, + { + "name": "sebastian/code-unit", + "version": "1.0.8", + "source": { + "type": "git", + "url": "https://github.com/sebastianbergmann/code-unit.git", + "reference": "1fc9f64c0927627ef78ba436c9b17d967e68e120" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/sebastianbergmann/code-unit/zipball/1fc9f64c0927627ef78ba436c9b17d967e68e120", + "reference": "1fc9f64c0927627ef78ba436c9b17d967e68e120", + "shasum": "" + }, + "require": { + "php": ">=7.3" + }, + "require-dev": { + "phpunit/phpunit": "^9.3" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.0-dev" + } + }, + "autoload": { + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de", + "role": "lead" + } + ], + "description": "Collection of value objects that represent the PHP code units", + "homepage": "https://github.com/sebastianbergmann/code-unit", + "support": { "issues": "https://github.com/sebastianbergmann/code-unit/issues", "source": "https://github.com/sebastianbergmann/code-unit/tree/1.0.8" }, @@ -2928,6 +3340,1233 @@ ], "time": "2020-09-28T06:39:44+00:00" }, + { + "name": "symfony/console", + "version": "v6.4.2", + "source": { + "type": "git", + "url": "https://github.com/symfony/console.git", + "reference": "0254811a143e6bc6c8deea08b589a7e68a37f625" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/console/zipball/0254811a143e6bc6c8deea08b589a7e68a37f625", + "reference": "0254811a143e6bc6c8deea08b589a7e68a37f625", + "shasum": "" + }, + "require": { + "php": ">=8.1", + "symfony/deprecation-contracts": "^2.5|^3", + "symfony/polyfill-mbstring": "~1.0", + "symfony/service-contracts": "^2.5|^3", + "symfony/string": "^5.4|^6.0|^7.0" + }, + "conflict": { + "symfony/dependency-injection": "<5.4", + "symfony/dotenv": "<5.4", + "symfony/event-dispatcher": "<5.4", + "symfony/lock": "<5.4", + "symfony/process": "<5.4" + }, + "provide": { + "psr/log-implementation": "1.0|2.0|3.0" + }, + "require-dev": { + "psr/log": "^1|^2|^3", + "symfony/config": "^5.4|^6.0|^7.0", + "symfony/dependency-injection": "^5.4|^6.0|^7.0", + "symfony/event-dispatcher": "^5.4|^6.0|^7.0", + "symfony/http-foundation": "^6.4|^7.0", + "symfony/http-kernel": "^6.4|^7.0", + "symfony/lock": "^5.4|^6.0|^7.0", + "symfony/messenger": "^5.4|^6.0|^7.0", + "symfony/process": "^5.4|^6.0|^7.0", + "symfony/stopwatch": "^5.4|^6.0|^7.0", + "symfony/var-dumper": "^5.4|^6.0|^7.0" + }, + "type": "library", + "autoload": { + "psr-4": { + "Symfony\\Component\\Console\\": "" + }, + "exclude-from-classmap": [ + "/Tests/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Fabien Potencier", + "email": "fabien@symfony.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Eases the creation of beautiful and testable command line interfaces", + "homepage": "https://symfony.com", + "keywords": [ + "cli", + "command-line", + "console", + "terminal" + ], + "support": { + "source": "https://github.com/symfony/console/tree/v6.4.2" + }, + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], + "time": "2023-12-10T16:15:48+00:00" + }, + { + "name": "symfony/event-dispatcher", + "version": "v6.4.2", + "source": { + "type": "git", + "url": "https://github.com/symfony/event-dispatcher.git", + "reference": "e95216850555cd55e71b857eb9d6c2674124603a" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/event-dispatcher/zipball/e95216850555cd55e71b857eb9d6c2674124603a", + "reference": "e95216850555cd55e71b857eb9d6c2674124603a", + "shasum": "" + }, + "require": { + "php": ">=8.1", + "symfony/event-dispatcher-contracts": "^2.5|^3" + }, + "conflict": { + "symfony/dependency-injection": "<5.4", + "symfony/service-contracts": "<2.5" + }, + "provide": { + "psr/event-dispatcher-implementation": "1.0", + "symfony/event-dispatcher-implementation": "2.0|3.0" + }, + "require-dev": { + "psr/log": "^1|^2|^3", + "symfony/config": "^5.4|^6.0|^7.0", + "symfony/dependency-injection": "^5.4|^6.0|^7.0", + "symfony/error-handler": "^5.4|^6.0|^7.0", + "symfony/expression-language": "^5.4|^6.0|^7.0", + "symfony/http-foundation": "^5.4|^6.0|^7.0", + "symfony/service-contracts": "^2.5|^3", + "symfony/stopwatch": "^5.4|^6.0|^7.0" + }, + "type": "library", + "autoload": { + "psr-4": { + "Symfony\\Component\\EventDispatcher\\": "" + }, + "exclude-from-classmap": [ + "/Tests/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Fabien Potencier", + "email": "fabien@symfony.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Provides tools that allow your application components to communicate with each other by dispatching events and listening to them", + "homepage": "https://symfony.com", + "support": { + "source": "https://github.com/symfony/event-dispatcher/tree/v6.4.2" + }, + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], + "time": "2023-12-27T22:16:42+00:00" + }, + { + "name": "symfony/event-dispatcher-contracts", + "version": "v3.4.0", + "source": { + "type": "git", + "url": "https://github.com/symfony/event-dispatcher-contracts.git", + "reference": "a76aed96a42d2b521153fb382d418e30d18b59df" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/event-dispatcher-contracts/zipball/a76aed96a42d2b521153fb382d418e30d18b59df", + "reference": "a76aed96a42d2b521153fb382d418e30d18b59df", + "shasum": "" + }, + "require": { + "php": ">=8.1", + "psr/event-dispatcher": "^1" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-main": "3.4-dev" + }, + "thanks": { + "name": "symfony/contracts", + "url": "https://github.com/symfony/contracts" + } + }, + "autoload": { + "psr-4": { + "Symfony\\Contracts\\EventDispatcher\\": "" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Nicolas Grekas", + "email": "p@tchwork.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Generic abstractions related to dispatching event", + "homepage": "https://symfony.com", + "keywords": [ + "abstractions", + "contracts", + "decoupling", + "interfaces", + "interoperability", + "standards" + ], + "support": { + "source": "https://github.com/symfony/event-dispatcher-contracts/tree/v3.4.0" + }, + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], + "time": "2023-05-23T14:45:45+00:00" + }, + { + "name": "symfony/filesystem", + "version": "v6.4.0", + "source": { + "type": "git", + "url": "https://github.com/symfony/filesystem.git", + "reference": "952a8cb588c3bc6ce76f6023000fb932f16a6e59" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/filesystem/zipball/952a8cb588c3bc6ce76f6023000fb932f16a6e59", + "reference": "952a8cb588c3bc6ce76f6023000fb932f16a6e59", + "shasum": "" + }, + "require": { + "php": ">=8.1", + "symfony/polyfill-ctype": "~1.8", + "symfony/polyfill-mbstring": "~1.8" + }, + "type": "library", + "autoload": { + "psr-4": { + "Symfony\\Component\\Filesystem\\": "" + }, + "exclude-from-classmap": [ + "/Tests/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Fabien Potencier", + "email": "fabien@symfony.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Provides basic utilities for the filesystem", + "homepage": "https://symfony.com", + "support": { + "source": "https://github.com/symfony/filesystem/tree/v6.4.0" + }, + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], + "time": "2023-07-26T17:27:13+00:00" + }, + { + "name": "symfony/finder", + "version": "v6.4.0", + "source": { + "type": "git", + "url": "https://github.com/symfony/finder.git", + "reference": "11d736e97f116ac375a81f96e662911a34cd50ce" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/finder/zipball/11d736e97f116ac375a81f96e662911a34cd50ce", + "reference": "11d736e97f116ac375a81f96e662911a34cd50ce", + "shasum": "" + }, + "require": { + "php": ">=8.1" + }, + "require-dev": { + "symfony/filesystem": "^6.0|^7.0" + }, + "type": "library", + "autoload": { + "psr-4": { + "Symfony\\Component\\Finder\\": "" + }, + "exclude-from-classmap": [ + "/Tests/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Fabien Potencier", + "email": "fabien@symfony.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Finds files and directories via an intuitive fluent interface", + "homepage": "https://symfony.com", + "support": { + "source": "https://github.com/symfony/finder/tree/v6.4.0" + }, + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], + "time": "2023-10-31T17:30:12+00:00" + }, + { + "name": "symfony/options-resolver", + "version": "v6.4.0", + "source": { + "type": "git", + "url": "https://github.com/symfony/options-resolver.git", + "reference": "22301f0e7fdeaacc14318928612dee79be99860e" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/options-resolver/zipball/22301f0e7fdeaacc14318928612dee79be99860e", + "reference": "22301f0e7fdeaacc14318928612dee79be99860e", + "shasum": "" + }, + "require": { + "php": ">=8.1", + "symfony/deprecation-contracts": "^2.5|^3" + }, + "type": "library", + "autoload": { + "psr-4": { + "Symfony\\Component\\OptionsResolver\\": "" + }, + "exclude-from-classmap": [ + "/Tests/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Fabien Potencier", + "email": "fabien@symfony.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Provides an improved replacement for the array_replace PHP function", + "homepage": "https://symfony.com", + "keywords": [ + "config", + "configuration", + "options" + ], + "support": { + "source": "https://github.com/symfony/options-resolver/tree/v6.4.0" + }, + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], + "time": "2023-08-08T10:16:24+00:00" + }, + { + "name": "symfony/polyfill-ctype", + "version": "v1.28.0", + "source": { + "type": "git", + "url": "https://github.com/symfony/polyfill-ctype.git", + "reference": "ea208ce43cbb04af6867b4fdddb1bdbf84cc28cb" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/polyfill-ctype/zipball/ea208ce43cbb04af6867b4fdddb1bdbf84cc28cb", + "reference": "ea208ce43cbb04af6867b4fdddb1bdbf84cc28cb", + "shasum": "" + }, + "require": { + "php": ">=7.1" + }, + "provide": { + "ext-ctype": "*" + }, + "suggest": { + "ext-ctype": "For best performance" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-main": "1.28-dev" + }, + "thanks": { + "name": "symfony/polyfill", + "url": "https://github.com/symfony/polyfill" + } + }, + "autoload": { + "files": [ + "bootstrap.php" + ], + "psr-4": { + "Symfony\\Polyfill\\Ctype\\": "" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Gert de Pagter", + "email": "BackEndTea@gmail.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Symfony polyfill for ctype functions", + "homepage": "https://symfony.com", + "keywords": [ + "compatibility", + "ctype", + "polyfill", + "portable" + ], + "support": { + "source": "https://github.com/symfony/polyfill-ctype/tree/v1.28.0" + }, + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], + "time": "2023-01-26T09:26:14+00:00" + }, + { + "name": "symfony/polyfill-intl-grapheme", + "version": "v1.28.0", + "source": { + "type": "git", + "url": "https://github.com/symfony/polyfill-intl-grapheme.git", + "reference": "875e90aeea2777b6f135677f618529449334a612" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/polyfill-intl-grapheme/zipball/875e90aeea2777b6f135677f618529449334a612", + "reference": "875e90aeea2777b6f135677f618529449334a612", + "shasum": "" + }, + "require": { + "php": ">=7.1" + }, + "suggest": { + "ext-intl": "For best performance" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-main": "1.28-dev" + }, + "thanks": { + "name": "symfony/polyfill", + "url": "https://github.com/symfony/polyfill" + } + }, + "autoload": { + "files": [ + "bootstrap.php" + ], + "psr-4": { + "Symfony\\Polyfill\\Intl\\Grapheme\\": "" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Nicolas Grekas", + "email": "p@tchwork.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Symfony polyfill for intl's grapheme_* functions", + "homepage": "https://symfony.com", + "keywords": [ + "compatibility", + "grapheme", + "intl", + "polyfill", + "portable", + "shim" + ], + "support": { + "source": "https://github.com/symfony/polyfill-intl-grapheme/tree/v1.28.0" + }, + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], + "time": "2023-01-26T09:26:14+00:00" + }, + { + "name": "symfony/polyfill-intl-normalizer", + "version": "v1.28.0", + "source": { + "type": "git", + "url": "https://github.com/symfony/polyfill-intl-normalizer.git", + "reference": "8c4ad05dd0120b6a53c1ca374dca2ad0a1c4ed92" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/polyfill-intl-normalizer/zipball/8c4ad05dd0120b6a53c1ca374dca2ad0a1c4ed92", + "reference": "8c4ad05dd0120b6a53c1ca374dca2ad0a1c4ed92", + "shasum": "" + }, + "require": { + "php": ">=7.1" + }, + "suggest": { + "ext-intl": "For best performance" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-main": "1.28-dev" + }, + "thanks": { + "name": "symfony/polyfill", + "url": "https://github.com/symfony/polyfill" + } + }, + "autoload": { + "files": [ + "bootstrap.php" + ], + "psr-4": { + "Symfony\\Polyfill\\Intl\\Normalizer\\": "" + }, + "classmap": [ + "Resources/stubs" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Nicolas Grekas", + "email": "p@tchwork.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Symfony polyfill for intl's Normalizer class and related functions", + "homepage": "https://symfony.com", + "keywords": [ + "compatibility", + "intl", + "normalizer", + "polyfill", + "portable", + "shim" + ], + "support": { + "source": "https://github.com/symfony/polyfill-intl-normalizer/tree/v1.28.0" + }, + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], + "time": "2023-01-26T09:26:14+00:00" + }, + { + "name": "symfony/polyfill-mbstring", + "version": "v1.28.0", + "source": { + "type": "git", + "url": "https://github.com/symfony/polyfill-mbstring.git", + "reference": "42292d99c55abe617799667f454222c54c60e229" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/polyfill-mbstring/zipball/42292d99c55abe617799667f454222c54c60e229", + "reference": "42292d99c55abe617799667f454222c54c60e229", + "shasum": "" + }, + "require": { + "php": ">=7.1" + }, + "provide": { + "ext-mbstring": "*" + }, + "suggest": { + "ext-mbstring": "For best performance" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-main": "1.28-dev" + }, + "thanks": { + "name": "symfony/polyfill", + "url": "https://github.com/symfony/polyfill" + } + }, + "autoload": { + "files": [ + "bootstrap.php" + ], + "psr-4": { + "Symfony\\Polyfill\\Mbstring\\": "" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Nicolas Grekas", + "email": "p@tchwork.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Symfony polyfill for the Mbstring extension", + "homepage": "https://symfony.com", + "keywords": [ + "compatibility", + "mbstring", + "polyfill", + "portable", + "shim" + ], + "support": { + "source": "https://github.com/symfony/polyfill-mbstring/tree/v1.28.0" + }, + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], + "time": "2023-07-28T09:04:16+00:00" + }, + { + "name": "symfony/polyfill-php80", + "version": "v1.28.0", + "source": { + "type": "git", + "url": "https://github.com/symfony/polyfill-php80.git", + "reference": "6caa57379c4aec19c0a12a38b59b26487dcfe4b5" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/polyfill-php80/zipball/6caa57379c4aec19c0a12a38b59b26487dcfe4b5", + "reference": "6caa57379c4aec19c0a12a38b59b26487dcfe4b5", + "shasum": "" + }, + "require": { + "php": ">=7.1" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-main": "1.28-dev" + }, + "thanks": { + "name": "symfony/polyfill", + "url": "https://github.com/symfony/polyfill" + } + }, + "autoload": { + "files": [ + "bootstrap.php" + ], + "psr-4": { + "Symfony\\Polyfill\\Php80\\": "" + }, + "classmap": [ + "Resources/stubs" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Ion Bazan", + "email": "ion.bazan@gmail.com" + }, + { + "name": "Nicolas Grekas", + "email": "p@tchwork.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Symfony polyfill backporting some PHP 8.0+ features to lower PHP versions", + "homepage": "https://symfony.com", + "keywords": [ + "compatibility", + "polyfill", + "portable", + "shim" + ], + "support": { + "source": "https://github.com/symfony/polyfill-php80/tree/v1.28.0" + }, + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], + "time": "2023-01-26T09:26:14+00:00" + }, + { + "name": "symfony/polyfill-php81", + "version": "v1.28.0", + "source": { + "type": "git", + "url": "https://github.com/symfony/polyfill-php81.git", + "reference": "7581cd600fa9fd681b797d00b02f068e2f13263b" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/polyfill-php81/zipball/7581cd600fa9fd681b797d00b02f068e2f13263b", + "reference": "7581cd600fa9fd681b797d00b02f068e2f13263b", + "shasum": "" + }, + "require": { + "php": ">=7.1" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-main": "1.28-dev" + }, + "thanks": { + "name": "symfony/polyfill", + "url": "https://github.com/symfony/polyfill" + } + }, + "autoload": { + "files": [ + "bootstrap.php" + ], + "psr-4": { + "Symfony\\Polyfill\\Php81\\": "" + }, + "classmap": [ + "Resources/stubs" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Nicolas Grekas", + "email": "p@tchwork.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Symfony polyfill backporting some PHP 8.1+ features to lower PHP versions", + "homepage": "https://symfony.com", + "keywords": [ + "compatibility", + "polyfill", + "portable", + "shim" + ], + "support": { + "source": "https://github.com/symfony/polyfill-php81/tree/v1.28.0" + }, + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], + "time": "2023-01-26T09:26:14+00:00" + }, + { + "name": "symfony/process", + "version": "v6.4.2", + "source": { + "type": "git", + "url": "https://github.com/symfony/process.git", + "reference": "c4b1ef0bc80533d87a2e969806172f1c2a980241" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/process/zipball/c4b1ef0bc80533d87a2e969806172f1c2a980241", + "reference": "c4b1ef0bc80533d87a2e969806172f1c2a980241", + "shasum": "" + }, + "require": { + "php": ">=8.1" + }, + "type": "library", + "autoload": { + "psr-4": { + "Symfony\\Component\\Process\\": "" + }, + "exclude-from-classmap": [ + "/Tests/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Fabien Potencier", + "email": "fabien@symfony.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Executes commands in sub-processes", + "homepage": "https://symfony.com", + "support": { + "source": "https://github.com/symfony/process/tree/v6.4.2" + }, + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], + "time": "2023-12-22T16:42:54+00:00" + }, + { + "name": "symfony/service-contracts", + "version": "v3.4.1", + "source": { + "type": "git", + "url": "https://github.com/symfony/service-contracts.git", + "reference": "fe07cbc8d837f60caf7018068e350cc5163681a0" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/service-contracts/zipball/fe07cbc8d837f60caf7018068e350cc5163681a0", + "reference": "fe07cbc8d837f60caf7018068e350cc5163681a0", + "shasum": "" + }, + "require": { + "php": ">=8.1", + "psr/container": "^1.1|^2.0" + }, + "conflict": { + "ext-psr": "<1.1|>=2" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-main": "3.4-dev" + }, + "thanks": { + "name": "symfony/contracts", + "url": "https://github.com/symfony/contracts" + } + }, + "autoload": { + "psr-4": { + "Symfony\\Contracts\\Service\\": "" + }, + "exclude-from-classmap": [ + "/Test/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Nicolas Grekas", + "email": "p@tchwork.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Generic abstractions related to writing services", + "homepage": "https://symfony.com", + "keywords": [ + "abstractions", + "contracts", + "decoupling", + "interfaces", + "interoperability", + "standards" + ], + "support": { + "source": "https://github.com/symfony/service-contracts/tree/v3.4.1" + }, + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], + "time": "2023-12-26T14:02:43+00:00" + }, + { + "name": "symfony/stopwatch", + "version": "v6.4.0", + "source": { + "type": "git", + "url": "https://github.com/symfony/stopwatch.git", + "reference": "fc47f1015ec80927ff64ba9094dfe8b9d48fe9f2" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/stopwatch/zipball/fc47f1015ec80927ff64ba9094dfe8b9d48fe9f2", + "reference": "fc47f1015ec80927ff64ba9094dfe8b9d48fe9f2", + "shasum": "" + }, + "require": { + "php": ">=8.1", + "symfony/service-contracts": "^2.5|^3" + }, + "type": "library", + "autoload": { + "psr-4": { + "Symfony\\Component\\Stopwatch\\": "" + }, + "exclude-from-classmap": [ + "/Tests/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Fabien Potencier", + "email": "fabien@symfony.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Provides a way to profile code", + "homepage": "https://symfony.com", + "support": { + "source": "https://github.com/symfony/stopwatch/tree/v6.4.0" + }, + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], + "time": "2023-02-16T10:14:28+00:00" + }, + { + "name": "symfony/string", + "version": "v6.4.2", + "source": { + "type": "git", + "url": "https://github.com/symfony/string.git", + "reference": "7cb80bc10bfcdf6b5492741c0b9357dac66940bc" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/string/zipball/7cb80bc10bfcdf6b5492741c0b9357dac66940bc", + "reference": "7cb80bc10bfcdf6b5492741c0b9357dac66940bc", + "shasum": "" + }, + "require": { + "php": ">=8.1", + "symfony/polyfill-ctype": "~1.8", + "symfony/polyfill-intl-grapheme": "~1.0", + "symfony/polyfill-intl-normalizer": "~1.0", + "symfony/polyfill-mbstring": "~1.0" + }, + "conflict": { + "symfony/translation-contracts": "<2.5" + }, + "require-dev": { + "symfony/error-handler": "^5.4|^6.0|^7.0", + "symfony/http-client": "^5.4|^6.0|^7.0", + "symfony/intl": "^6.2|^7.0", + "symfony/translation-contracts": "^2.5|^3.0", + "symfony/var-exporter": "^5.4|^6.0|^7.0" + }, + "type": "library", + "autoload": { + "files": [ + "Resources/functions.php" + ], + "psr-4": { + "Symfony\\Component\\String\\": "" + }, + "exclude-from-classmap": [ + "/Tests/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Nicolas Grekas", + "email": "p@tchwork.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Provides an object-oriented API to strings and deals with bytes, UTF-8 code points and grapheme clusters in a unified way", + "homepage": "https://symfony.com", + "keywords": [ + "grapheme", + "i18n", + "string", + "unicode", + "utf-8", + "utf8" + ], + "support": { + "source": "https://github.com/symfony/string/tree/v6.4.2" + }, + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], + "time": "2023-12-10T16:15:48+00:00" + }, { "name": "theseer/tokenizer", "version": "1.2.1", diff --git a/src/CTClient.php b/src/CTClient.php index d30dfc3d..fcbfb7a4 100644 --- a/src/CTClient.php +++ b/src/CTClient.php @@ -1,9 +1,7 @@ getMessage(), $exception->getCode(), $exception); - } else if ($exception instanceof GuzzleException) { + } elseif ($exception instanceof GuzzleException) { throw new CTRequestException($exception->getMessage(), $exception->getCode(), $exception); } throw $exception; @@ -127,4 +125,4 @@ public static function createClient(?HandlerStack $handlerStack = null): CTClien return new CTClient(['handler' => $handlerStack]); } } -} \ No newline at end of file +} diff --git a/src/CTConfig.php b/src/CTConfig.php index 4f8497e4..14c97bd4 100644 --- a/src/CTConfig.php +++ b/src/CTConfig.php @@ -251,4 +251,4 @@ public static function clearCache(): void CTCacheMiddleware::getCacheDriver()->deleteAll(); CTCacheMiddleware::getCacheDriver()->flushAll(); } -} \ No newline at end of file +} diff --git a/src/CTLog.php b/src/CTLog.php index 58c98ef7..16fcd23f 100644 --- a/src/CTLog.php +++ b/src/CTLog.php @@ -1,9 +1,7 @@ warning("CTAuthException: " . $message); } -} \ No newline at end of file +} diff --git a/src/Exceptions/CTConfigException.php b/src/Exceptions/CTConfigException.php index dcc37573..81a0189a 100644 --- a/src/Exceptions/CTConfigException.php +++ b/src/Exceptions/CTConfigException.php @@ -1,9 +1,7 @@ warning("CTConfigException: " . $message); } -} \ No newline at end of file +} diff --git a/src/Exceptions/CTConnectException.php b/src/Exceptions/CTConnectException.php index 73f48c2e..864c1537 100644 --- a/src/Exceptions/CTConnectException.php +++ b/src/Exceptions/CTConnectException.php @@ -1,9 +1,7 @@ warning("CTConfigException: " . $message); } -} \ No newline at end of file +} diff --git a/src/Exceptions/CTModelException.php b/src/Exceptions/CTModelException.php index 3dd9e366..3a8d1513 100644 --- a/src/Exceptions/CTModelException.php +++ b/src/Exceptions/CTModelException.php @@ -1,9 +1,7 @@ warning("CTModelException: " . $message); } -} \ No newline at end of file +} diff --git a/src/Exceptions/CTPermissionException.php b/src/Exceptions/CTPermissionException.php index 321ecd46..01d516b4 100644 --- a/src/Exceptions/CTPermissionException.php +++ b/src/Exceptions/CTPermissionException.php @@ -1,9 +1,7 @@ warning("CTPermissionException: " . $message); } -} \ No newline at end of file +} diff --git a/src/Exceptions/CTRequestException.php b/src/Exceptions/CTRequestException.php index a43f71f2..9cd73c16 100644 --- a/src/Exceptions/CTRequestException.php +++ b/src/Exceptions/CTRequestException.php @@ -1,6 +1,5 @@ longitude = $longitude; return $this; } -} \ No newline at end of file +} diff --git a/src/Models/Calendars/Appointment/Appointment.php b/src/Models/Calendars/Appointment/Appointment.php index 4a991557..f43c2c72 100644 --- a/src/Models/Calendars/Appointment/Appointment.php +++ b/src/Models/Calendars/Appointment/Appointment.php @@ -1,9 +1,7 @@ calculated_endDate = $calculated_endDate; } -} \ No newline at end of file +} diff --git a/src/Models/Calendars/Appointment/AppointmentRequest.php b/src/Models/Calendars/Appointment/AppointmentRequest.php index efca615a..ed617942 100644 --- a/src/Models/Calendars/Appointment/AppointmentRequest.php +++ b/src/Models/Calendars/Appointment/AppointmentRequest.php @@ -1,9 +1,7 @@ getId())){ + if(!is_null($this->getId())) { return new AppointmentRequestBuilder([$this->getId()]); - }else{ + } else { return null; } } @@ -251,4 +250,4 @@ public function setMeta(?Meta $meta): Calendar $this->meta = $meta; return $this; } -} \ No newline at end of file +} diff --git a/src/Models/Calendars/Calendar/CalendarRequest.php b/src/Models/Calendars/Calendar/CalendarRequest.php index ac7a0787..c959c490 100644 --- a/src/Models/Calendars/Calendar/CalendarRequest.php +++ b/src/Models/Calendars/Calendar/CalendarRequest.php @@ -1,9 +1,7 @@ orderBy($key, $orderAscending); } -} \ No newline at end of file +} diff --git a/src/Models/Calendars/Calendar/CalendarRequestBuilder.php b/src/Models/Calendars/Calendar/CalendarRequestBuilder.php index 791cc75b..e6d88cc3 100644 --- a/src/Models/Calendars/Calendar/CalendarRequestBuilder.php +++ b/src/Models/Calendars/Calendar/CalendarRequestBuilder.php @@ -1,9 +1,7 @@ meetingRequests; -// } -// -// /** -// * @param array of MeetingRequests $meetingRequests -// * @return CombinedAppointment -// */ -// public function setMeetingRequests(?array $meetingRequests): CombinedAppointment -// { -// $this->meetingRequests = $meetingRequests; -// return $this; -// } -// -} \ No newline at end of file + // + // Not yet implemented, missing MeetingRequests base class implementation + // + // /** + // * @return array of MeetingRequest or NULL + // */ + // public function getMeetingRequests(): ?array + // { + // return $this->meetingRequests; + // } + // + // /** + // * @param array of MeetingRequests $meetingRequests + // * @return CombinedAppointment + // */ + // public function setMeetingRequests(?array $meetingRequests): CombinedAppointment + // { + // $this->meetingRequests = $meetingRequests; + // return $this; + // } + // +} diff --git a/src/Models/Calendars/CombinedAppointment/CombinedAppointmentRequest.php b/src/Models/Calendars/CombinedAppointment/CombinedAppointmentRequest.php index 11912beb..721e6bfc 100644 --- a/src/Models/Calendars/CombinedAppointment/CombinedAppointmentRequest.php +++ b/src/Models/Calendars/CombinedAppointment/CombinedAppointmentRequest.php @@ -1,9 +1,7 @@ collectDataFromPages("/api/calendars/". $this->calendarId ."/appointments/". $this->appointmentId ."/". $this->startDate); + $data = $this->collectDataFromPages("/api/calendars/". $this->calendarId ."/appointments/". $this->appointmentId ."/". $this->startDate); - return CombinedAppointment::createModelFromData($data); + return CombinedAppointment::createModelFromData($data); } -} \ No newline at end of file +} diff --git a/src/Models/Calendars/Resource/Resource.php b/src/Models/Calendars/Resource/Resource.php index 7d6549ff..aa3e563e 100644 --- a/src/Models/Calendars/Resource/Resource.php +++ b/src/Models/Calendars/Resource/Resource.php @@ -1,9 +1,7 @@ randomString = $randomString; return $this; } -} \ No newline at end of file +} diff --git a/src/Models/Calendars/Resource/ResourceBooking.php b/src/Models/Calendars/Resource/ResourceBooking.php index 4d00751a..d870bf0f 100644 --- a/src/Models/Calendars/Resource/ResourceBooking.php +++ b/src/Models/Calendars/Resource/ResourceBooking.php @@ -1,9 +1,7 @@ meta = $meta; return $this; } -} \ No newline at end of file +} diff --git a/src/Models/Calendars/Resource/ResourceBookingsRequest.php b/src/Models/Calendars/Resource/ResourceBookingsRequest.php index 8082a537..25d2a275 100644 --- a/src/Models/Calendars/Resource/ResourceBookingsRequest.php +++ b/src/Models/Calendars/Resource/ResourceBookingsRequest.php @@ -1,9 +1,7 @@ all(); } -} \ No newline at end of file +} diff --git a/src/Models/Calendars/Resource/ResourceRequestBuilder.php b/src/Models/Calendars/Resource/ResourceRequestBuilder.php index 683cdca7..075f1787 100644 --- a/src/Models/Calendars/Resource/ResourceRequestBuilder.php +++ b/src/Models/Calendars/Resource/ResourceRequestBuilder.php @@ -1,9 +1,7 @@ campusId = $campusId; return $this; } -} \ No newline at end of file +} diff --git a/src/Models/Common/Auth/Auth.php b/src/Models/Common/Auth/Auth.php index bafcfe1d..c8170bbd 100644 --- a/src/Models/Common/Auth/Auth.php +++ b/src/Models/Common/Auth/Auth.php @@ -4,12 +4,11 @@ class Auth { - function __construct( + public function __construct( public $userId, public bool $requireMultiFactorAuthentication = false - ) - { + ) { } -} \ No newline at end of file +} diff --git a/src/Models/Common/Auth/AuthRequest.php b/src/Models/Common/Auth/AuthRequest.php index 120780f9..665e59bb 100644 --- a/src/Models/Common/Auth/AuthRequest.php +++ b/src/Models/Common/Auth/AuthRequest.php @@ -4,7 +4,6 @@ use CTApi\CTLog; - class AuthRequest { public static function authWithEmailAndPassword(string $email, string $password): Auth @@ -36,4 +35,4 @@ public static function retrieveApiToken(string $userId): ?string CTLog::getLog()->info('AuthRequest: Request API-Token.'); return (new AuthRequestBuilder())->retrieveApiToken($userId); } -} \ No newline at end of file +} diff --git a/src/Models/Common/Auth/AuthRequestBuilder.php b/src/Models/Common/Auth/AuthRequestBuilder.php index 363ffec8..d904fe7a 100644 --- a/src/Models/Common/Auth/AuthRequestBuilder.php +++ b/src/Models/Common/Auth/AuthRequestBuilder.php @@ -30,7 +30,8 @@ public function authWithEmailAndPassword(string $email, string $password): Auth throw new CTAuthException( "Authentication was not successfully. HTTP Exception occurred.", 0, - $e); + $e + ); } if ($response->getStatusCode() == 200) { @@ -118,4 +119,4 @@ public function authTwoFactorAuthentication(string $personId, string $totp) $client = CTClient::getClient(); $client->post('/api/login/totp', ["json" => ["personId" => $personId, "code" => $totp]]); } -} \ No newline at end of file +} diff --git a/src/Models/Common/Auth/CSRFTokenRequest.php b/src/Models/Common/Auth/CSRFTokenRequest.php index c7e7129d..449b315e 100644 --- a/src/Models/Common/Auth/CSRFTokenRequest.php +++ b/src/Models/Common/Auth/CSRFTokenRequest.php @@ -1,9 +1,7 @@ get('/api/config'); return CTResponseUtil::jsonToArray($response); } -} \ No newline at end of file +} diff --git a/src/Models/Common/DBField/DBField.php b/src/Models/Common/DBField/DBField.php index d4924e3b..82793406 100644 --- a/src/Models/Common/DBField/DBField.php +++ b/src/Models/Common/DBField/DBField.php @@ -1,9 +1,7 @@ useAsPlaceholder = $useAsPlaceholder; return $this; } -} \ No newline at end of file +} diff --git a/src/Models/Common/DBField/DBFieldCategory.php b/src/Models/Common/DBField/DBFieldCategory.php index c262785f..7beab90c 100644 --- a/src/Models/Common/DBField/DBFieldCategory.php +++ b/src/Models/Common/DBField/DBFieldCategory.php @@ -1,9 +1,7 @@ table = $table; return $this; } -} \ No newline at end of file +} diff --git a/src/Models/Common/DBField/DBFieldContainer.php b/src/Models/Common/DBField/DBFieldContainer.php index a05ed962..19cddfce 100644 --- a/src/Models/Common/DBField/DBFieldContainer.php +++ b/src/Models/Common/DBField/DBFieldContainer.php @@ -1,9 +1,7 @@ dbField = DBField::createModelFromData($data); - }else{ + } else { $this->fillDefault($key, $data); } } @@ -69,4 +67,4 @@ public function setDbField(?DBField $dbField): DBFieldContainer $this->dbField = $dbField; return $this; } -} \ No newline at end of file +} diff --git a/src/Models/Common/DBField/DBFieldForKeysRequestBuilder.php b/src/Models/Common/DBField/DBFieldForKeysRequestBuilder.php index 7c941650..c3f93510 100644 --- a/src/Models/Common/DBField/DBFieldForKeysRequestBuilder.php +++ b/src/Models/Common/DBField/DBFieldForKeysRequestBuilder.php @@ -1,9 +1,7 @@ internCode = $internCode; return $this; } -} \ No newline at end of file +} diff --git a/src/Models/Common/DBField/DBFieldValueContainer.php b/src/Models/Common/DBField/DBFieldValueContainer.php index 9bbe6307..6eeb48ba 100644 --- a/src/Models/Common/DBField/DBFieldValueContainer.php +++ b/src/Models/Common/DBField/DBFieldValueContainer.php @@ -1,18 +1,14 @@ DBField = $DBField; return $this; } -} \ No newline at end of file +} diff --git a/src/Models/Common/Domain/DomainAttributeModel.php b/src/Models/Common/Domain/DomainAttributeModel.php index 5685e0b9..d625ee0b 100644 --- a/src/Models/Common/Domain/DomainAttributeModel.php +++ b/src/Models/Common/Domain/DomainAttributeModel.php @@ -1,13 +1,12 @@ modifiedPerson = $modifiedPerson; return $this; } -} \ No newline at end of file +} diff --git a/src/Models/Common/File/File.php b/src/Models/Common/File/File.php index e83958f6..418fa795 100644 --- a/src/Models/Common/File/File.php +++ b/src/Models/Common/File/File.php @@ -1,9 +1,7 @@ size = $size; return $this; } -} \ No newline at end of file +} diff --git a/src/Models/Common/File/FileRequest.php b/src/Models/Common/File/FileRequest.php index b0f4839a..236d3a26 100644 --- a/src/Models/Common/File/FileRequest.php +++ b/src/Models/Common/File/FileRequest.php @@ -1,9 +1,7 @@ delete('/api/files/' . $file->getIdOrFail()); } -} \ No newline at end of file +} diff --git a/src/Models/Common/File/FileRequestBuilder.php b/src/Models/Common/File/FileRequestBuilder.php index ffaadc90..8ddfb5c7 100644 --- a/src/Models/Common/File/FileRequestBuilder.php +++ b/src/Models/Common/File/FileRequestBuilder.php @@ -1,9 +1,7 @@ warning("Could not convert upload response to JSON: " . $resultString); $data = []; } diff --git a/src/Models/Common/Info/InfoRequest.php b/src/Models/Common/Info/InfoRequest.php index 2c23d60f..89de344c 100644 --- a/src/Models/Common/Info/InfoRequest.php +++ b/src/Models/Common/Info/InfoRequest.php @@ -1,9 +1,7 @@ get('/api/info'); return CTResponseUtil::jsonToArray($response); } -} \ No newline at end of file +} diff --git a/src/Models/Common/Permission/PermissionChurchCal.php b/src/Models/Common/Permission/PermissionChurchCal.php index d0d272ee..4b1a578b 100644 --- a/src/Models/Common/Permission/PermissionChurchCal.php +++ b/src/Models/Common/Permission/PermissionChurchCal.php @@ -1,9 +1,7 @@ admin_church_category = $admin_church_category; return $this; } -} \ No newline at end of file +} diff --git a/src/Models/Common/Permission/PermissionChurchCheckin.php b/src/Models/Common/Permission/PermissionChurchCheckin.php index 9871f982..1760684a 100644 --- a/src/Models/Common/Permission/PermissionChurchCheckin.php +++ b/src/Models/Common/Permission/PermissionChurchCheckin.php @@ -1,9 +1,7 @@ simulate_persons = $simulate_persons; return $this; } -} \ No newline at end of file +} diff --git a/src/Models/Common/Permission/PermissionChurchDb.php b/src/Models/Common/Permission/PermissionChurchDb.php index 55f15a97..7e06a31e 100644 --- a/src/Models/Common/Permission/PermissionChurchDb.php +++ b/src/Models/Common/Permission/PermissionChurchDb.php @@ -1,9 +1,7 @@ edit_masterdata = $edit_masterdata; return $this; } -} \ No newline at end of file +} diff --git a/src/Models/Common/Permission/PermissionChurchResource.php b/src/Models/Common/Permission/PermissionChurchResource.php index 7d41ec26..7a919b60 100644 --- a/src/Models/Common/Permission/PermissionChurchResource.php +++ b/src/Models/Common/Permission/PermissionChurchResource.php @@ -1,9 +1,7 @@ edit_masterdata = $edit_masterdata; return $this; } -} \ No newline at end of file +} diff --git a/src/Models/Common/Permission/PermissionChurchService.php b/src/Models/Common/Permission/PermissionChurchService.php index 94d92013..4fe998da 100644 --- a/src/Models/Common/Permission/PermissionChurchService.php +++ b/src/Models/Common/Permission/PermissionChurchService.php @@ -1,9 +1,7 @@ edit_masterdata = $edit_masterdata; return $this; } -} \ No newline at end of file +} diff --git a/src/Models/Common/Permission/PermissionChurchWiki.php b/src/Models/Common/Permission/PermissionChurchWiki.php index 8ca7385d..57d4c227 100644 --- a/src/Models/Common/Permission/PermissionChurchWiki.php +++ b/src/Models/Common/Permission/PermissionChurchWiki.php @@ -1,9 +1,7 @@ edit_masterdata = $edit_masterdata; return $this; } -} \ No newline at end of file +} diff --git a/src/Models/Common/Permission/PermissionGlobal.php b/src/Models/Common/Permission/PermissionGlobal.php index 4ce592ad..b789ac5e 100644 --- a/src/Models/Common/Permission/PermissionGlobal.php +++ b/src/Models/Common/Permission/PermissionGlobal.php @@ -1,9 +1,7 @@ churchcheckin = $churchcheckin; return $this; } -} \ No newline at end of file +} diff --git a/src/Models/Common/Permission/PermissionGlobalRequestBuilder.php b/src/Models/Common/Permission/PermissionGlobalRequestBuilder.php index 14d7bb8e..082cef24 100644 --- a/src/Models/Common/Permission/PermissionGlobalRequestBuilder.php +++ b/src/Models/Common/Permission/PermissionGlobalRequestBuilder.php @@ -1,9 +1,7 @@ domainTypes)){ + if(!in_array($domainType, $this->domainTypes)) { $this->domainTypes[] = $domainType; } return $this; @@ -34,8 +31,8 @@ public function get(): array ] ]; - if(!empty($this->domainTypes)){ - CTUtil::arrayPathSet($options,"json.domainTypes", $this->domainTypes); + if(!empty($this->domainTypes)) { + CTUtil::arrayPathSet($options, "json.domainTypes", $this->domainTypes); } $client = CTClient::getClient(); @@ -43,4 +40,4 @@ public function get(): array $data = CTResponseUtil::dataAsArray($response); return SearchResult::createModelsFromArray($data); } -} \ No newline at end of file +} diff --git a/src/Models/Common/Search/SearchResult.php b/src/Models/Common/Search/SearchResult.php index 8581c25e..b2fe45af 100644 --- a/src/Models/Common/Search/SearchResult.php +++ b/src/Models/Common/Search/SearchResult.php @@ -1,15 +1,14 @@ icon = $icon; return $this; } -} \ No newline at end of file +} diff --git a/src/Models/Common/Tag/Tag.php b/src/Models/Common/Tag/Tag.php index ae4ed98b..7fe77295 100644 --- a/src/Models/Common/Tag/Tag.php +++ b/src/Models/Common/Tag/Tag.php @@ -1,9 +1,7 @@ count = $count; return $this; } -} \ No newline at end of file +} diff --git a/src/Models/Common/Tag/TagRequest.php b/src/Models/Common/Tag/TagRequest.php index 27cf2783..c4db553e 100644 --- a/src/Models/Common/Tag/TagRequest.php +++ b/src/Models/Common/Tag/TagRequest.php @@ -1,9 +1,7 @@ findOrFail($id); } -} \ No newline at end of file +} diff --git a/src/Models/Common/Tag/TagRequestBuilder.php b/src/Models/Common/Tag/TagRequestBuilder.php index 503c72fe..6301236d 100644 --- a/src/Models/Common/Tag/TagRequestBuilder.php +++ b/src/Models/Common/Tag/TagRequestBuilder.php @@ -1,9 +1,7 @@ tags = $this->retrieveData(); } @@ -29,11 +26,11 @@ private function retrieveData(): array private function filterTag(int $tagId): ?Tag { - $filteredTags = array_filter($this->tags, function(Tag $tag) use ($tagId){ - return $tag->getIdAsInteger() == $tagId; + $filteredTags = array_filter($this->tags, function (Tag $tag) use ($tagId) { + return $tag->getIdAsInteger() == $tagId; }); $foundTag = end($filteredTags); - if($foundTag === false){ + if($foundTag === false) { return null; } return $foundTag; @@ -47,7 +44,7 @@ public function find(int $id): ?Tag public function findOrFail(int $id): Tag { $tag = $this->find($id); - if($tag == null){ + if($tag == null) { throw CTRequestException::ofModelNotFound(Tag::class); } return $tag; @@ -57,4 +54,4 @@ public function all(): array { return $this->tags; } -} \ No newline at end of file +} diff --git a/src/Models/Events/Absence/Absence.php b/src/Models/Events/Absence/Absence.php index 7ef10722..6907a77a 100644 --- a/src/Models/Events/Absence/Absence.php +++ b/src/Models/Events/Absence/Absence.php @@ -1,9 +1,7 @@ person = $person; return $this; } -} \ No newline at end of file +} diff --git a/src/Models/Events/Absence/AbsencePersonRequestBuilder.php b/src/Models/Events/Absence/AbsencePersonRequestBuilder.php index 0ed9c764..f8182958 100644 --- a/src/Models/Events/Absence/AbsencePersonRequestBuilder.php +++ b/src/Models/Events/Absence/AbsencePersonRequestBuilder.php @@ -1,9 +1,7 @@ deleteData($id); } -} \ No newline at end of file +} diff --git a/src/Models/Events/Absence/AbsenceReason.php b/src/Models/Events/Absence/AbsenceReason.php index cfc3d6ac..12925589 100644 --- a/src/Models/Events/Absence/AbsenceReason.php +++ b/src/Models/Events/Absence/AbsenceReason.php @@ -1,9 +1,7 @@ sortKey = $sortKey; return $this; } -} \ No newline at end of file +} diff --git a/src/Models/Events/Absence/AbsenceRequest.php b/src/Models/Events/Absence/AbsenceRequest.php index 475bb94f..da5b514e 100644 --- a/src/Models/Events/Absence/AbsenceRequest.php +++ b/src/Models/Events/Absence/AbsenceRequest.php @@ -1,9 +1,7 @@ delete($absence); } -} \ No newline at end of file +} diff --git a/src/Models/Events/Event/Event.php b/src/Models/Events/Event/Event.php index 45801805..1b57152a 100644 --- a/src/Models/Events/Event/Event.php +++ b/src/Models/Events/Event/Event.php @@ -1,9 +1,7 @@ setCalendar(DomainAttributeModel::createModelFromData($data)); break; case "domainAttributes": - if(key_exists("startDate", $data)){ + if(key_exists("startDate", $data)) { $this->setStartDate($data["startDate"]); } break; @@ -51,7 +49,7 @@ protected function fillArrayType(string $key, array $data): void protected function fillNonArrayType(string $key, $value): void { - switch ($key){ + switch ($key) { case "title": $this->setName($value); break; @@ -286,4 +284,4 @@ public function setEventServices(?array $eventServices): Event $this->eventServices = $eventServices; return $this; } -} \ No newline at end of file +} diff --git a/src/Models/Events/Event/EventAgenda.php b/src/Models/Events/Event/EventAgenda.php index d7d71a23..a451c2ed 100644 --- a/src/Models/Events/Event/EventAgenda.php +++ b/src/Models/Events/Event/EventAgenda.php @@ -1,9 +1,7 @@ items = $items; return $this; } -} \ No newline at end of file +} diff --git a/src/Models/Events/Event/EventAgendaItem.php b/src/Models/Events/Event/EventAgendaItem.php index de319836..00d247be 100644 --- a/src/Models/Events/Event/EventAgendaItem.php +++ b/src/Models/Events/Event/EventAgendaItem.php @@ -1,9 +1,7 @@ song = $song; return $this; } -} \ No newline at end of file +} diff --git a/src/Models/Events/Event/EventAgendaRequest.php b/src/Models/Events/Event/EventAgendaRequest.php index 0b34d9e1..6c3c5c08 100644 --- a/src/Models/Events/Event/EventAgendaRequest.php +++ b/src/Models/Events/Event/EventAgendaRequest.php @@ -1,13 +1,11 @@ get('/api/events/' . $this->eventId . '/agenda'); return EventAgenda::createModelFromData(CTResponseUtil::dataAsArray($response)); } -} \ No newline at end of file +} diff --git a/src/Models/Events/Event/EventRequest.php b/src/Models/Events/Event/EventRequest.php index 7b5b9255..a4ead2d7 100644 --- a/src/Models/Events/Event/EventRequest.php +++ b/src/Models/Events/Event/EventRequest.php @@ -1,9 +1,7 @@ find($id); } -} \ No newline at end of file +} diff --git a/src/Models/Events/Event/EventRequestBuilder.php b/src/Models/Events/Event/EventRequestBuilder.php index 8511c3ed..05d9969c 100644 --- a/src/Models/Events/Event/EventRequestBuilder.php +++ b/src/Models/Events/Event/EventRequestBuilder.php @@ -1,14 +1,11 @@ allowChat = $allowChat; return $this; } -} \ No newline at end of file +} diff --git a/src/Models/Events/Service/Service.php b/src/Models/Events/Service/Service.php index 59b2b550..08f66aad 100644 --- a/src/Models/Events/Service/Service.php +++ b/src/Models/Events/Service/Service.php @@ -1,9 +1,7 @@ allowChat = $allowChat; return $this; } -} \ No newline at end of file +} diff --git a/src/Models/Events/Service/ServiceFromServiceGroupBuilder.php b/src/Models/Events/Service/ServiceFromServiceGroupBuilder.php index d852872a..2ff5611c 100644 --- a/src/Models/Events/Service/ServiceFromServiceGroupBuilder.php +++ b/src/Models/Events/Service/ServiceFromServiceGroupBuilder.php @@ -1,9 +1,7 @@ onlyVisibleInCampusFilter = $onlyVisibleInCampusFilter; return $this; } -} \ No newline at end of file +} diff --git a/src/Models/Events/Service/ServiceGroupRequest.php b/src/Models/Events/Service/ServiceGroupRequest.php index a24416e8..0207a99c 100644 --- a/src/Models/Events/Service/ServiceGroupRequest.php +++ b/src/Models/Events/Service/ServiceGroupRequest.php @@ -1,9 +1,7 @@ find($id); } -} \ No newline at end of file +} diff --git a/src/Models/Events/Service/ServiceRequestBuilder.php b/src/Models/Events/Service/ServiceRequestBuilder.php index d02f80f4..652d2af8 100644 --- a/src/Models/Events/Service/ServiceRequestBuilder.php +++ b/src/Models/Events/Service/ServiceRequestBuilder.php @@ -1,14 +1,11 @@ id != null){ + if($this->id != null) { return new SongTagRequestBuilder($this->getIdAsInteger()); } return null; @@ -371,4 +371,4 @@ public function setIsDefault(?bool $isDefault): Song $this->isDefault = $isDefault; return $this; } -} \ No newline at end of file +} diff --git a/src/Models/Events/Song/SongArrangement.php b/src/Models/Events/Song/SongArrangement.php index d05091c4..ea5a4763 100644 --- a/src/Models/Events/Song/SongArrangement.php +++ b/src/Models/Events/Song/SongArrangement.php @@ -1,9 +1,7 @@ files = $files; return $this; } -} \ No newline at end of file +} diff --git a/src/Models/Events/Song/SongArrangementRequest.php b/src/Models/Events/Song/SongArrangementRequest.php index 007d6cb4..7bde4094 100644 --- a/src/Models/Events/Song/SongArrangementRequest.php +++ b/src/Models/Events/Song/SongArrangementRequest.php @@ -1,13 +1,11 @@ update($songArrangement); } -} \ No newline at end of file +} diff --git a/src/Models/Events/Song/SongArrangementRequestBuilder.php b/src/Models/Events/Song/SongArrangementRequestBuilder.php index 5860b42b..b6e9fa00 100644 --- a/src/Models/Events/Song/SongArrangementRequestBuilder.php +++ b/src/Models/Events/Song/SongArrangementRequestBuilder.php @@ -1,9 +1,7 @@ songArrangements; } -} \ No newline at end of file +} diff --git a/src/Models/Events/Song/SongArrangementUpdateRequestBuilder.php b/src/Models/Events/Song/SongArrangementUpdateRequestBuilder.php index 8f9305d6..5406195f 100644 --- a/src/Models/Events/Song/SongArrangementUpdateRequestBuilder.php +++ b/src/Models/Events/Song/SongArrangementUpdateRequestBuilder.php @@ -1,9 +1,7 @@ meta = $meta; return $this; } -} \ No newline at end of file +} diff --git a/src/Models/Events/Song/SongCommentRequest.php b/src/Models/Events/Song/SongCommentRequest.php index 3169560e..7592f659 100644 --- a/src/Models/Events/Song/SongCommentRequest.php +++ b/src/Models/Events/Song/SongCommentRequest.php @@ -4,7 +4,6 @@ class SongCommentRequest { - public static function getForSongArrangement(int $arrangementId): array { $builder = new SongCommentRequestBuilder($arrangementId); @@ -23,4 +22,4 @@ public static function delete(int $commentId): void $builder->deleteComment($commentId); } -} \ No newline at end of file +} diff --git a/src/Models/Events/Song/SongCommentRequestBuilder.php b/src/Models/Events/Song/SongCommentRequestBuilder.php index 0c493494..ff4002be 100644 --- a/src/Models/Events/Song/SongCommentRequestBuilder.php +++ b/src/Models/Events/Song/SongCommentRequestBuilder.php @@ -7,13 +7,11 @@ class SongCommentRequestBuilder { - use AjaxApi; public function __construct( private int $arrangementId - ) - { + ) { } public function getComments() @@ -43,4 +41,4 @@ public function deleteComment(int $commentId): void ]); } -} \ No newline at end of file +} diff --git a/src/Models/Events/Song/SongLyrics.php b/src/Models/Events/Song/SongLyrics.php index 59db2cad..1ed5e569 100644 --- a/src/Models/Events/Song/SongLyrics.php +++ b/src/Models/Events/Song/SongLyrics.php @@ -1,9 +1,7 @@ title = $title; return $this; } -} \ No newline at end of file +} diff --git a/src/Models/Events/Song/SongRequest.php b/src/Models/Events/Song/SongRequest.php index 358ae47f..715c5f91 100644 --- a/src/Models/Events/Song/SongRequest.php +++ b/src/Models/Events/Song/SongRequest.php @@ -1,9 +1,7 @@ update($song); } -} \ No newline at end of file +} diff --git a/src/Models/Events/Song/SongRequestBuilder.php b/src/Models/Events/Song/SongRequestBuilder.php index 8ad07355..7f0ec560 100644 --- a/src/Models/Events/Song/SongRequestBuilder.php +++ b/src/Models/Events/Song/SongRequestBuilder.php @@ -1,9 +1,7 @@ requestAjax("churchservice/ajax", "getAllSongs", []); $data = CTResponseUtil::dataAsArray($response); - if(array_key_exists("songs", $data)){ + if(array_key_exists("songs", $data)) { return $data["songs"]; - }else{ + } else { return $data; } } -} \ No newline at end of file +} diff --git a/src/Models/Events/Song/SongUpdateRequestBuilder.php b/src/Models/Events/Song/SongUpdateRequestBuilder.php index 666edf5c..22689a06 100644 --- a/src/Models/Events/Song/SongUpdateRequestBuilder.php +++ b/src/Models/Events/Song/SongUpdateRequestBuilder.php @@ -1,9 +1,7 @@ requestAjax("churchservice/ajax", "editSong", $updateAttributes); $data = CTResponseUtil::jsonToArray($response); } -} \ No newline at end of file +} diff --git a/src/Models/Events/SongStatistic/SongStatistic.php b/src/Models/Events/SongStatistic/SongStatistic.php index 79b856b7..d12a64d0 100644 --- a/src/Models/Events/SongStatistic/SongStatistic.php +++ b/src/Models/Events/SongStatistic/SongStatistic.php @@ -1,9 +1,7 @@ find($arrangementId); } -} \ No newline at end of file +} diff --git a/src/Models/Events/SongStatistic/SongStatisticRequestBuilder.php b/src/Models/Events/SongStatistic/SongStatisticRequestBuilder.php index c80e0b53..fea234b5 100644 --- a/src/Models/Events/SongStatistic/SongStatisticRequestBuilder.php +++ b/src/Models/Events/SongStatistic/SongStatisticRequestBuilder.php @@ -1,9 +1,7 @@ roles = $roles; return $this; } -} \ No newline at end of file +} diff --git a/src/Models/Groups/Group/GroupCategory.php b/src/Models/Groups/Group/GroupCategory.php index 88326c26..250d8b81 100644 --- a/src/Models/Groups/Group/GroupCategory.php +++ b/src/Models/Groups/Group/GroupCategory.php @@ -1,9 +1,7 @@ sortKey = $sortKey; return $this; } -} \ No newline at end of file +} diff --git a/src/Models/Groups/Group/GroupHierarchieChildrenRequest.php b/src/Models/Groups/Group/GroupHierarchieChildrenRequest.php index aa01cfad..a3492172 100644 --- a/src/Models/Groups/Group/GroupHierarchieChildrenRequest.php +++ b/src/Models/Groups/Group/GroupHierarchieChildrenRequest.php @@ -1,9 +1,7 @@ groups = $groups; return $this; } -} \ No newline at end of file +} diff --git a/src/Models/Groups/Group/GroupInformation.php b/src/Models/Groups/Group/GroupInformation.php index 69f2e3da..f55c2a25 100644 --- a/src/Models/Groups/Group/GroupInformation.php +++ b/src/Models/Groups/Group/GroupInformation.php @@ -1,16 +1,15 @@ imageUrl = $imageUrl; return $this; } -} \ No newline at end of file +} diff --git a/src/Models/Groups/Group/GroupPlace.php b/src/Models/Groups/Group/GroupPlace.php index 27108215..3dd871c8 100644 --- a/src/Models/Groups/Group/GroupPlace.php +++ b/src/Models/Groups/Group/GroupPlace.php @@ -1,9 +1,7 @@ createdPerson = Person::createModelFromData($data); break; @@ -200,4 +198,4 @@ public function setCreatedPerson(?Person $createdPerson): GroupPlace $this->createdPerson = $createdPerson; return $this; } -} \ No newline at end of file +} diff --git a/src/Models/Groups/Group/GroupRequest.php b/src/Models/Groups/Group/GroupRequest.php index ba3b6753..9a3798d8 100644 --- a/src/Models/Groups/Group/GroupRequest.php +++ b/src/Models/Groups/Group/GroupRequest.php @@ -1,9 +1,7 @@ find($id); } -} \ No newline at end of file +} diff --git a/src/Models/Groups/Group/GroupRequestBuilder.php b/src/Models/Groups/Group/GroupRequestBuilder.php index 6417fa97..4f8df79b 100644 --- a/src/Models/Groups/Group/GroupRequestBuilder.php +++ b/src/Models/Groups/Group/GroupRequestBuilder.php @@ -1,14 +1,11 @@ canWriteChat = $canWriteChat; return $this; } -} \ No newline at end of file +} diff --git a/src/Models/Groups/Group/GroupSettings.php b/src/Models/Groups/Group/GroupSettings.php index 13850a28..c5a813bb 100644 --- a/src/Models/Groups/Group/GroupSettings.php +++ b/src/Models/Groups/Group/GroupSettings.php @@ -1,9 +1,7 @@ newMember = $newMember; return $this; } -} \ No newline at end of file +} diff --git a/src/Models/Groups/Group/GroupTagRequestBuilder.php b/src/Models/Groups/Group/GroupTagRequestBuilder.php index b5b294d4..eff1ed4b 100644 --- a/src/Models/Groups/Group/GroupTagRequestBuilder.php +++ b/src/Models/Groups/Group/GroupTagRequestBuilder.php @@ -1,20 +1,16 @@ admin_group_chat = $admin_group_chat; return $this; } -} \ No newline at end of file +} diff --git a/src/Models/Groups/Group/TargetGroup.php b/src/Models/Groups/Group/TargetGroup.php index e99199b0..f32674b2 100644 --- a/src/Models/Groups/Group/TargetGroup.php +++ b/src/Models/Groups/Group/TargetGroup.php @@ -1,9 +1,7 @@ sortKey = $sortKey; return $this; } -} \ No newline at end of file +} diff --git a/src/Models/Groups/GroupMeeting/GroupMeeting.php b/src/Models/Groups/GroupMeeting/GroupMeeting.php index 28283041..e56d7a7d 100644 --- a/src/Models/Groups/GroupMeeting/GroupMeeting.php +++ b/src/Models/Groups/GroupMeeting/GroupMeeting.php @@ -1,9 +1,7 @@ statistics = $statistics; return $this; } -} \ No newline at end of file +} diff --git a/src/Models/Groups/GroupMeeting/GroupMeetingMember.php b/src/Models/Groups/GroupMeeting/GroupMeetingMember.php index b4f9ec28..a2d0a7a3 100644 --- a/src/Models/Groups/GroupMeeting/GroupMeetingMember.php +++ b/src/Models/Groups/GroupMeeting/GroupMeetingMember.php @@ -1,9 +1,7 @@ member = $member; return $this; } -} \ No newline at end of file +} diff --git a/src/Models/Groups/GroupMeeting/GroupMeetingMemberRequestBuilder.php b/src/Models/Groups/GroupMeeting/GroupMeetingMemberRequestBuilder.php index 6412f8f2..151b1759 100644 --- a/src/Models/Groups/GroupMeeting/GroupMeetingMemberRequestBuilder.php +++ b/src/Models/Groups/GroupMeeting/GroupMeetingMemberRequestBuilder.php @@ -1,20 +1,16 @@ unsure = $unsure; return $this; } -} \ No newline at end of file +} diff --git a/src/Models/Groups/GroupMember/GroupMember.php b/src/Models/Groups/GroupMember/GroupMember.php index 4c2466bd..0c073087 100644 --- a/src/Models/Groups/GroupMember/GroupMember.php +++ b/src/Models/Groups/GroupMember/GroupMember.php @@ -1,9 +1,7 @@ followUpUnsuccessfulBackGroupId = $followUpUnsuccessfulBackGroupId; return $this; } -} \ No newline at end of file +} diff --git a/src/Models/Groups/GroupMember/GroupMemberField.php b/src/Models/Groups/GroupMember/GroupMemberField.php index cde9fc00..07fb57d4 100644 --- a/src/Models/Groups/GroupMember/GroupMemberField.php +++ b/src/Models/Groups/GroupMember/GroupMemberField.php @@ -1,9 +1,7 @@ options = $options; return $this; } -} \ No newline at end of file +} diff --git a/src/Models/Groups/GroupMember/GroupMemberFieldContainer.php b/src/Models/Groups/GroupMember/GroupMemberFieldContainer.php index 3dbcfcba..4289448b 100644 --- a/src/Models/Groups/GroupMember/GroupMemberFieldContainer.php +++ b/src/Models/Groups/GroupMember/GroupMemberFieldContainer.php @@ -1,9 +1,7 @@ type = $value; $this->loadFieldLazy(); } @@ -30,7 +28,7 @@ protected function fillNonArrayType(string $key, $value): void protected function fillArrayType(string $key, array $data): void { - switch ($key){ + switch ($key) { case "field": $this->fieldData = $data; $this->loadFieldLazy(); @@ -42,8 +40,8 @@ protected function fillArrayType(string $key, array $data): void private function loadFieldLazy() { - if($this->type != null && $this->fieldData != null && $this->field == null){ - switch ($this->type){ + if($this->type != null && $this->fieldData != null && $this->field == null) { + switch ($this->type) { case "group": $this->field = GroupMemberField::createModelFromData($this->fieldData); break; @@ -56,7 +54,7 @@ private function loadFieldLazy() public function getDBFieldIfExists(): ?DBField { - if(is_a($this->field, DBFieldContainer::class)){ + if(is_a($this->field, DBFieldContainer::class)) { return $this->field->getDbField(); } return null; @@ -64,7 +62,7 @@ public function getDBFieldIfExists(): ?DBField public function getGroupMemberFieldIfExists(): ?GroupMemberField { - if(is_a($this->field, GroupMemberField::class)){ + if(is_a($this->field, GroupMemberField::class)) { return $this->field; } return null; @@ -141,4 +139,4 @@ public function setRequiredInRegistrationForm(?bool $requiredInRegistrationForm) $this->requiredInRegistrationForm = $requiredInRegistrationForm; return $this; } -} \ No newline at end of file +} diff --git a/src/Models/Groups/GroupMember/GroupMemberFieldsRequest.php b/src/Models/Groups/GroupMember/GroupMemberFieldsRequest.php index 5c5cb521..130e01b4 100644 --- a/src/Models/Groups/GroupMember/GroupMemberFieldsRequest.php +++ b/src/Models/Groups/GroupMember/GroupMemberFieldsRequest.php @@ -1,13 +1,11 @@ removeMember($personId); } -} \ No newline at end of file +} diff --git a/src/Models/Groups/GroupMember/GroupMemberRequestBuilder.php b/src/Models/Groups/GroupMember/GroupMemberRequestBuilder.php index 631affd6..ab64c34e 100644 --- a/src/Models/Groups/GroupMember/GroupMemberRequestBuilder.php +++ b/src/Models/Groups/GroupMember/GroupMemberRequestBuilder.php @@ -1,19 +1,18 @@ groupId = $groupId; } @@ -26,4 +25,4 @@ public function get(): array return GroupMember::createModelsFromArray($data); } -} \ No newline at end of file +} diff --git a/src/Models/Groups/GroupMember/GroupMemberUpdateRequestBuilder.php b/src/Models/Groups/GroupMember/GroupMemberUpdateRequestBuilder.php index ca26ecf7..e78192fd 100644 --- a/src/Models/Groups/GroupMember/GroupMemberUpdateRequestBuilder.php +++ b/src/Models/Groups/GroupMember/GroupMemberUpdateRequestBuilder.php @@ -1,19 +1,16 @@ delete("/api/groups/" . $this->groupId . "/members/" . $personId); } -} \ No newline at end of file +} diff --git a/src/Models/Groups/Person/BirthdayPerson.php b/src/Models/Groups/Person/BirthdayPerson.php index 0bb2f39e..a72ade5b 100644 --- a/src/Models/Groups/Person/BirthdayPerson.php +++ b/src/Models/Groups/Person/BirthdayPerson.php @@ -1,9 +1,7 @@ person = $person; return $this; } -} \ No newline at end of file +} diff --git a/src/Models/Groups/Person/InternalPersonPermission.php b/src/Models/Groups/Person/InternalPersonPermission.php index 750d6935..22698b74 100644 --- a/src/Models/Groups/Person/InternalPersonPermission.php +++ b/src/Models/Groups/Person/InternalPersonPermission.php @@ -1,9 +1,7 @@ do_followup = $do_followup; return $this; } -} \ No newline at end of file +} diff --git a/src/Models/Groups/Person/Person.php b/src/Models/Groups/Person/Person.php index b619a817..1a1873db 100644 --- a/src/Models/Groups/Person/Person.php +++ b/src/Models/Groups/Person/Person.php @@ -1,9 +1,7 @@ isArchived = $isArchived; return $this; } -} \ No newline at end of file +} diff --git a/src/Models/Groups/Person/PersonBirthdayRequestBuilder.php b/src/Models/Groups/Person/PersonBirthdayRequestBuilder.php index 1eb961f0..1910a98c 100644 --- a/src/Models/Groups/Person/PersonBirthdayRequestBuilder.php +++ b/src/Models/Groups/Person/PersonBirthdayRequestBuilder.php @@ -1,9 +1,7 @@ memberStartDate = $memberStartDate; return $this; } -} \ No newline at end of file +} diff --git a/src/Models/Groups/Person/PersonGroupRequestBuilder.php b/src/Models/Groups/Person/PersonGroupRequestBuilder.php index f23f954b..0a212926 100644 --- a/src/Models/Groups/Person/PersonGroupRequestBuilder.php +++ b/src/Models/Groups/Person/PersonGroupRequestBuilder.php @@ -1,15 +1,14 @@ delete($person); } -} \ No newline at end of file +} diff --git a/src/Models/Groups/Person/PersonRequestBuilder.php b/src/Models/Groups/Person/PersonRequestBuilder.php index 7730d53d..393d7d9a 100644 --- a/src/Models/Groups/Person/PersonRequestBuilder.php +++ b/src/Models/Groups/Person/PersonRequestBuilder.php @@ -1,6 +1,5 @@ signUpHeadline = $signUpHeadline; return $this; } -} \ No newline at end of file +} diff --git a/src/Models/Groups/PublicGroup/PublicGroupRequest.php b/src/Models/Groups/PublicGroup/PublicGroupRequest.php index 9edee86f..f59b8db5 100644 --- a/src/Models/Groups/PublicGroup/PublicGroupRequest.php +++ b/src/Models/Groups/PublicGroup/PublicGroupRequest.php @@ -1,9 +1,7 @@ get(); } -} \ No newline at end of file +} diff --git a/src/Models/Groups/PublicGroup/PublicGroupRequestBuilder.php b/src/Models/Groups/PublicGroup/PublicGroupRequestBuilder.php index bfe05de4..80806c83 100644 --- a/src/Models/Groups/PublicGroup/PublicGroupRequestBuilder.php +++ b/src/Models/Groups/PublicGroup/PublicGroupRequestBuilder.php @@ -1,16 +1,13 @@ getId())) { - return WikiPageRequestBuilder::requestPageFromCategoryAndIdentifier( $this->getIdOrFail(), $identifier); + return WikiPageRequestBuilder::requestPageFromCategoryAndIdentifier($this->getIdOrFail(), $identifier); } else { return null; } @@ -191,4 +189,4 @@ public function setPermissions(array $permissions): WikiCategory $this->permissions = $permissions; return $this; } -} \ No newline at end of file +} diff --git a/src/Models/Wiki/WikiCategory/WikiCategoryRequest.php b/src/Models/Wiki/WikiCategory/WikiCategoryRequest.php index 02eb4692..73b9f7d8 100644 --- a/src/Models/Wiki/WikiCategory/WikiCategoryRequest.php +++ b/src/Models/Wiki/WikiCategory/WikiCategoryRequest.php @@ -1,12 +1,9 @@ all(); @@ -21,4 +18,4 @@ public static function find(int $id): ?WikiCategory { return (new WikiCategoryRequestBuilder())->find($id); } -} \ No newline at end of file +} diff --git a/src/Models/Wiki/WikiCategory/WikiCategoryRequestBuilder.php b/src/Models/Wiki/WikiCategory/WikiCategoryRequestBuilder.php index d63c82bc..2236758e 100644 --- a/src/Models/Wiki/WikiCategory/WikiCategoryRequestBuilder.php +++ b/src/Models/Wiki/WikiCategory/WikiCategoryRequestBuilder.php @@ -1,15 +1,12 @@ text = $text; return $this; } -} \ No newline at end of file +} diff --git a/src/Models/Wiki/WikiPage/WikiPageFilesRequestBuilder.php b/src/Models/Wiki/WikiPage/WikiPageFilesRequestBuilder.php index 7b4e72dd..b1e9312c 100644 --- a/src/Models/Wiki/WikiPage/WikiPageFilesRequestBuilder.php +++ b/src/Models/Wiki/WikiPage/WikiPageFilesRequestBuilder.php @@ -1,9 +1,7 @@ getTitle()) . ']]'; // => Found Link to $subPage <= - if (str_contains( (string) $page->getText(), $linkString)) { + if (str_contains((string) $page->getText(), $linkString)) { $subPagesArray[] = [ - 'stringPos' => strpos( (string) $page->getText(), $linkString), + 'stringPos' => strpos((string) $page->getText(), $linkString), 'node' => self::processWikiPage($subPage, $pages, $pageTreeNode) ]; } @@ -136,4 +133,4 @@ public function setChildNodes(array $childNodes): WikiPageTreeNode $this->childNodes = $childNodes; return $this; } -} \ No newline at end of file +} diff --git a/src/Models/Wiki/WikiPage/WikiPageVersionRequestBuilder.php b/src/Models/Wiki/WikiPage/WikiPageVersionRequestBuilder.php index 71fb0f26..8a8c3045 100644 --- a/src/Models/Wiki/WikiPage/WikiPageVersionRequestBuilder.php +++ b/src/Models/Wiki/WikiPage/WikiPageVersionRequestBuilder.php @@ -1,16 +1,13 @@ search($query); } -} \ No newline at end of file +} diff --git a/src/Models/Wiki/WikiSearch/WikiSearchRequestBuilder.php b/src/Models/Wiki/WikiSearch/WikiSearchRequestBuilder.php index e8a9a058..30f7e8bc 100644 --- a/src/Models/Wiki/WikiSearch/WikiSearchRequestBuilder.php +++ b/src/Models/Wiki/WikiSearch/WikiSearchRequestBuilder.php @@ -1,9 +1,7 @@ query = $query; @@ -55,4 +54,4 @@ public static function requestWikiPageFromRawUrl(string $url): ?WikiPage return null; } -} \ No newline at end of file +} diff --git a/src/Models/Wiki/WikiSearch/WikiSearchResult.php b/src/Models/Wiki/WikiSearch/WikiSearchResult.php index 2ea95d17..d27611c7 100644 --- a/src/Models/Wiki/WikiSearch/WikiSearchResult.php +++ b/src/Models/Wiki/WikiSearch/WikiSearchResult.php @@ -1,23 +1,22 @@ getApiUrl())) { - return WikiSearchRequestBuilder::requestWikiPageFromRawUrl( (string) $this->getApiUrl()); + return WikiSearchRequestBuilder::requestWikiPageFromRawUrl((string) $this->getApiUrl()); } return null; } @@ -39,4 +38,4 @@ public function setPreview(?string $preview): WikiSearchResult $this->preview = $preview; return $this; } -} \ No newline at end of file +} diff --git a/src/Traits/Model/DomainAttribute.php b/src/Traits/Model/DomainAttribute.php index 7b924803..f7690930 100644 --- a/src/Traits/Model/DomainAttribute.php +++ b/src/Traits/Model/DomainAttribute.php @@ -1,9 +1,7 @@ domainAttributes = $domainAttributes; return $this; } -} \ No newline at end of file +} diff --git a/src/Traits/Model/FillWithData.php b/src/Traits/Model/FillWithData.php index 0b17b3d4..a7c5470e 100644 --- a/src/Traits/Model/FillWithData.php +++ b/src/Traits/Model/FillWithData.php @@ -45,7 +45,7 @@ private function castPropertyToData($propertyValue) { if (is_object($propertyValue)) { // cast objects return $this->castObjectToData($propertyValue); - } else if (is_array($propertyValue)) { + } elseif (is_array($propertyValue)) { return $this->castArrayToData($propertyValue); } else { return $propertyValue; @@ -75,7 +75,7 @@ public function fillWithData(array $array): void foreach ($array as $key => $value) { if (is_object($value)) { $this->fillObjectType($key, $value); - } else if (is_array($value)) { + } elseif (is_array($value)) { $this->fillArrayType($key, $value); } else { $this->fillNonArrayType($key, $value); @@ -257,7 +257,7 @@ private function castToString(string $valueType, $value): ?string { if ($valueType == "bool") { return $value ? "true" : "false"; - } else if ($valueType == "int" || $valueType == "float") { + } elseif ($valueType == "int" || $valueType == "float") { return strval($value); } @@ -300,4 +300,4 @@ public static function createModelFromData(array $data): self $model->fillWithData($data); return $model; } -} \ No newline at end of file +} diff --git a/src/Traits/Model/HasDBFields.php b/src/Traits/Model/HasDBFields.php index 911ae1e2..0cfdd56c 100644 --- a/src/Traits/Model/HasDBFields.php +++ b/src/Traits/Model/HasDBFields.php @@ -1,9 +1,7 @@ getDBFieldData()); } -} \ No newline at end of file +} diff --git a/src/Traits/Model/MetaAttribute.php b/src/Traits/Model/MetaAttribute.php index b1d98284..7dff0a3a 100644 --- a/src/Traits/Model/MetaAttribute.php +++ b/src/Traits/Model/MetaAttribute.php @@ -1,9 +1,7 @@ $translatedData ]); } -} \ No newline at end of file +} diff --git a/src/Traits/Request/OrderByCondition.php b/src/Traits/Request/OrderByCondition.php index 11675db7..41af9ff8 100644 --- a/src/Traits/Request/OrderByCondition.php +++ b/src/Traits/Request/OrderByCondition.php @@ -1,9 +1,7 @@ withBody(new CTMessageBody($data)); return $response; } -} \ No newline at end of file +} diff --git a/src/Utils/CTDateTimeService.php b/src/Utils/CTDateTimeService.php index cb697ec4..1f977c13 100644 --- a/src/Utils/CTDateTimeService.php +++ b/src/Utils/CTDateTimeService.php @@ -1,9 +1,7 @@ uri = $uri; return $this; } -} \ No newline at end of file +} diff --git a/src/Utils/CTResponse.php b/src/Utils/CTResponse.php index 578b4742..fe9cc775 100644 --- a/src/Utils/CTResponse.php +++ b/src/Utils/CTResponse.php @@ -1,9 +1,7 @@ statusReasonPhrase; } -} \ No newline at end of file +} diff --git a/src/Utils/CTResponseUtil.php b/src/Utils/CTResponseUtil.php index 0677bed1..4592b93a 100644 --- a/src/Utils/CTResponseUtil.php +++ b/src/Utils/CTResponseUtil.php @@ -1,9 +1,7 @@ info("CacheTest: Execution-time with cache: " . $timeWithCache . " secs"); CTLog::getLog()->info("CacheTest: With cache the whole execution was " . ((int)($percentFaster * 100)) . " % faster"); - $this->assertGreaterThan($timeWithCache, $timeWithoutCache,); + $this->assertGreaterThan($timeWithCache, $timeWithoutCache, ); $this->assertGreaterThan(0.1, $percentFaster); } @@ -83,4 +83,4 @@ public function runSongRequests(int $numberOfRequests = 10): float return $time; } -} \ No newline at end of file +} diff --git a/tests/Integration/Config/AuthWithLoginTokenTest.php b/tests/Integration/Config/AuthWithLoginTokenTest.php index ef4079ca..b85478fd 100644 --- a/tests/Integration/Config/AuthWithLoginTokenTest.php +++ b/tests/Integration/Config/AuthWithLoginTokenTest.php @@ -1,9 +1,7 @@ authenticateUser("jona"); } -} \ No newline at end of file +} diff --git a/tests/Integration/Config/TwoFactorAuthenticationTest.php b/tests/Integration/Config/TwoFactorAuthenticationTest.php index 76052211..7364d1e7 100644 --- a/tests/Integration/Config/TwoFactorAuthenticationTest.php +++ b/tests/Integration/Config/TwoFactorAuthenticationTest.php @@ -1,9 +1,7 @@ assertFalse(empty($groups)); } -} \ No newline at end of file +} diff --git a/tests/Integration/Exceptions/AuthExceptionTest.php b/tests/Integration/Exceptions/AuthExceptionTest.php index 75fb8ff1..fff4ac71 100644 --- a/tests/Integration/Exceptions/AuthExceptionTest.php +++ b/tests/Integration/Exceptions/AuthExceptionTest.php @@ -29,4 +29,4 @@ public function testWrongApiKey(): void CTConfig::setApiKey("wrong-api-key"); $person = PersonRequest::whoami(); } -} \ No newline at end of file +} diff --git a/tests/Integration/Exceptions/ConfigExceptionTest.php b/tests/Integration/Exceptions/ConfigExceptionTest.php index 66ab5bcd..2fb332ea 100644 --- a/tests/Integration/Exceptions/ConfigExceptionTest.php +++ b/tests/Integration/Exceptions/ConfigExceptionTest.php @@ -27,4 +27,4 @@ public function testApiUrlEmptyValidate(): void // CTConfig: API-Url is not set CTConfig::validateConfig(); } -} \ No newline at end of file +} diff --git a/tests/Integration/Exceptions/ConnectExceptionTest.php b/tests/Integration/Exceptions/ConnectExceptionTest.php index eaa8e777..108ce4ec 100644 --- a/tests/Integration/Exceptions/ConnectExceptionTest.php +++ b/tests/Integration/Exceptions/ConnectExceptionTest.php @@ -2,7 +2,6 @@ namespace CTApi\Test\Integration\Exceptions; - use CTApi\CTConfig; use CTApi\Exceptions\CTConnectException; use CTApi\Models\Groups\Person\PersonRequest; @@ -21,4 +20,4 @@ public function testApiUrlInvalidServer(): void CTConfig::setApiUrl("http://novalidsubdomain.lukasdumberger.de/"); PersonRequest::whoami(); } -} \ No newline at end of file +} diff --git a/tests/Integration/Exceptions/ModelExceptionTest.php b/tests/Integration/Exceptions/ModelExceptionTest.php index 27acfb49..32d4deef 100644 --- a/tests/Integration/Exceptions/ModelExceptionTest.php +++ b/tests/Integration/Exceptions/ModelExceptionTest.php @@ -2,7 +2,6 @@ namespace CTApi\Test\Integration\Exceptions; - use CTApi\Exceptions\CTModelException; use CTApi\Models\Wiki\WikiPage\WikiPageTreeNode; use PHPUnit\Framework\TestCase; @@ -14,4 +13,4 @@ public function testNoRootWikiPage(): void $this->expectException(CTModelException::class); WikiPageTreeNode::processWikiPagesReturnRootNode([]); } -} \ No newline at end of file +} diff --git a/tests/Integration/Exceptions/RequestExceptionTest.php b/tests/Integration/Exceptions/RequestExceptionTest.php index abdad282..6cc41d6b 100644 --- a/tests/Integration/Exceptions/RequestExceptionTest.php +++ b/tests/Integration/Exceptions/RequestExceptionTest.php @@ -13,4 +13,4 @@ public function testModelNotFound(): void $this->expectException(CTRequestException::class); EventRequest::findOrFail(99999999); } -} \ No newline at end of file +} diff --git a/tests/Integration/IntegrationTestCase.php b/tests/Integration/IntegrationTestCase.php index 28c1e6be..ef90da4a 100644 --- a/tests/Integration/IntegrationTestCase.php +++ b/tests/Integration/IntegrationTestCase.php @@ -1,9 +1,7 @@ data)){ + if(!array_key_exists("filter", $this->data)) { throw new \Exception("Could not find filter for test case: " . $this->testCase); } return CTUtil::arrayPathGet($this->data["filter"], $filterPath); @@ -26,7 +23,7 @@ public function getFilter(string $filterPath) public function getFilterAsInt(string $filterPath): int { $value = $this->getFilter($filterPath); - if($value === null){ + if($value === null) { throw new \Exception("Cannot convert null to int"); } return (int) $value; @@ -34,7 +31,7 @@ public function getFilterAsInt(string $filterPath): int public function getResult(string $resultPath) { - if(!array_key_exists("result", $this->data)){ + if(!array_key_exists("result", $this->data)) { throw new \Exception("Could not find results for test case: " . $this->testCase); } return CTUtil::arrayPathGet($this->data["result"], $resultPath); @@ -43,9 +40,9 @@ public function getResult(string $resultPath) public function getResultAsInt(string $resultPath): int { $value = $this->getResult($resultPath); - if($value === null){ + if($value === null) { throw new \Exception("Cannot convert null to int"); } return (int) $value; } -} \ No newline at end of file +} diff --git a/tests/Integration/IntegrationTestData.php b/tests/Integration/IntegrationTestData.php index e1d57446..c06caaf6 100644 --- a/tests/Integration/IntegrationTestData.php +++ b/tests/Integration/IntegrationTestData.php @@ -1,9 +1,7 @@ testCases[$testCaseIdentifier]; } -} \ No newline at end of file +} diff --git a/tests/Integration/Models/MetaTest.php b/tests/Integration/Models/MetaTest.php index 2d983990..f1e53364 100644 --- a/tests/Integration/Models/MetaTest.php +++ b/tests/Integration/Models/MetaTest.php @@ -11,7 +11,6 @@ use CTApi\Test\Integration\IntegrationTestData; use CTApi\Test\Integration\TestCaseAuthenticated; - class MetaTest extends TestCaseAuthenticated { public function testPersonMeta(): void @@ -74,4 +73,4 @@ private function assertModelHasValidMeta($model): void // ignore } } -} \ No newline at end of file +} diff --git a/tests/Integration/Requests/APIVersionTest.php b/tests/Integration/Requests/APIVersionTest.php index 263df31c..45d06c20 100644 --- a/tests/Integration/Requests/APIVersionTest.php +++ b/tests/Integration/Requests/APIVersionTest.php @@ -1,18 +1,14 @@ (.*)<\/version>/"; @@ -39,4 +35,4 @@ private function setVersionInReadme(string $newVersion) $str = preg_replace(self::$VERSION_REGEX, "" . $newVersion . "", $str); file_put_contents(self::$README_FILE, $str); } -} \ No newline at end of file +} diff --git a/tests/Integration/Requests/AbsenceRequestTest.php b/tests/Integration/Requests/AbsenceRequestTest.php index 3d347a72..bf2278fb 100644 --- a/tests/Integration/Requests/AbsenceRequestTest.php +++ b/tests/Integration/Requests/AbsenceRequestTest.php @@ -1,9 +1,7 @@ assertEquals($absenceA->getComment(), $absenceB->getComment()); } -} \ No newline at end of file +} diff --git a/tests/Integration/Requests/AuthRequestTest.php b/tests/Integration/Requests/AuthRequestTest.php index 51d19296..768655b4 100644 --- a/tests/Integration/Requests/AuthRequestTest.php +++ b/tests/Integration/Requests/AuthRequestTest.php @@ -9,7 +9,6 @@ class AuthRequestTest extends TestCase { - public function setUp(): void { $apiUrl = IntegrationTestData::get()->getApiUrl(); diff --git a/tests/Integration/Requests/BookingsRequestTest.php b/tests/Integration/Requests/BookingsRequestTest.php index a99a0910..6bc1c409 100644 --- a/tests/Integration/Requests/BookingsRequestTest.php +++ b/tests/Integration/Requests/BookingsRequestTest.php @@ -1,9 +1,7 @@ assertEquals($this->bookingCaption2, $foundBooking2->getCaption()); } -} \ No newline at end of file +} diff --git a/tests/Integration/Requests/CalendarRequestTest.php b/tests/Integration/Requests/CalendarRequestTest.php index e260483b..b17adf00 100644 --- a/tests/Integration/Requests/CalendarRequestTest.php +++ b/tests/Integration/Requests/CalendarRequestTest.php @@ -1,9 +1,7 @@ getResult("second_series_appointment.calculated_start_date"); - foreach($appointments as $appointment){ - if($first_startDate === $appointment->getStartDate()){ + foreach($appointments as $appointment) { + if($first_startDate === $appointment->getStartDate()) { $firstSeriesAppointment = $appointment; } - if($second_startDate === $appointment->getStartDate()){ + if($second_startDate === $appointment->getStartDate()) { $secondSeriesAppointment = $appointment; } } @@ -137,4 +134,4 @@ public function testSeriesAppointment() $this->assertNotNull($secondSeriesAppointment); $this->assertEquals($testCase->getResult("second_series_appointment.base_start_date"), $secondSeriesAppointment->getBaseStartDate()); } -} \ No newline at end of file +} diff --git a/tests/Integration/Requests/CcliRequestTest.php b/tests/Integration/Requests/CcliRequestTest.php index 117c5dc4..5aa2316e 100644 --- a/tests/Integration/Requests/CcliRequestTest.php +++ b/tests/Integration/Requests/CcliRequestTest.php @@ -1,9 +1,7 @@ songArrangementId)->get()); $this->assertEquals($numberOfFilesAfterCleanUp, $numberOfFilesBevorRequest); } -} \ No newline at end of file +} diff --git a/tests/Integration/Requests/DBFieldRequestTest.php b/tests/Integration/Requests/DBFieldRequestTest.php index d837f25d..f21c4c2f 100644 --- a/tests/Integration/Requests/DBFieldRequestTest.php +++ b/tests/Integration/Requests/DBFieldRequestTest.php @@ -1,9 +1,7 @@ assertEqualsTestData("db_field_group", "db_field.name", $name5pmDBField->getDBField()->getName()); $this->assertEqualsTestData("db_field_group", "value", $name5pmDBField->getDBFieldValue()); } -} \ No newline at end of file +} diff --git a/tests/Integration/Requests/EventAgendaTest.php b/tests/Integration/Requests/EventAgendaTest.php index d0ec7ec1..8f6bbe6a 100644 --- a/tests/Integration/Requests/EventAgendaTest.php +++ b/tests/Integration/Requests/EventAgendaTest.php @@ -10,10 +10,8 @@ use CTApi\Test\Integration\IntegrationTestData; use CTApi\Test\Integration\TestCaseAuthenticated; - class EventAgendaTest extends TestCaseAuthenticated { - public function testGetAgenda(): void { $eventId = IntegrationTestData::getFilter("get_event_agenda", "event_id"); diff --git a/tests/Integration/Requests/EventRequestTest.php b/tests/Integration/Requests/EventRequestTest.php index 7dd27ca7..6b8ed59c 100644 --- a/tests/Integration/Requests/EventRequestTest.php +++ b/tests/Integration/Requests/EventRequestTest.php @@ -11,10 +11,8 @@ use CTApi\Test\Integration\IntegrationTestData; use CTApi\Test\Integration\TestCaseAuthenticated; - class EventRequestTest extends TestCaseAuthenticated { - public function testGetAllEvents(): void { $allEvents = EventRequest::all(); @@ -134,4 +132,4 @@ public function testRequestEventServiceWithServiceId(): void $eventService = $event->requestEventServiceWithServiceId(92814821428); $this->assertNull($eventService); } -} \ No newline at end of file +} diff --git a/tests/Integration/Requests/FileRequestAvatarTest.php b/tests/Integration/Requests/FileRequestAvatarTest.php index 00dba2e1..c9c81d78 100644 --- a/tests/Integration/Requests/FileRequestAvatarTest.php +++ b/tests/Integration/Requests/FileRequestAvatarTest.php @@ -1,9 +1,7 @@ myselfId)->get(); $this->assertEmpty($filesReloaded); } -} \ No newline at end of file +} diff --git a/tests/Integration/Requests/FileRequestMultipleFilesTest.php b/tests/Integration/Requests/FileRequestMultipleFilesTest.php index 97a5cd82..27b22acc 100644 --- a/tests/Integration/Requests/FileRequestMultipleFilesTest.php +++ b/tests/Integration/Requests/FileRequestMultipleFilesTest.php @@ -1,16 +1,13 @@ assertNotNull($foundChild); $this->assertEquals($this->groupChildName, $foundChild->getName()); } -} \ No newline at end of file +} diff --git a/tests/Integration/Requests/GroupMeetingRequestTest.php b/tests/Integration/Requests/GroupMeetingRequestTest.php index 2946a654..d5910cda 100644 --- a/tests/Integration/Requests/GroupMeetingRequestTest.php +++ b/tests/Integration/Requests/GroupMeetingRequestTest.php @@ -1,16 +1,13 @@ assertNotNull($foundMember); } -} \ No newline at end of file +} diff --git a/tests/Integration/Requests/GroupMemberFieldsTest.php b/tests/Integration/Requests/GroupMemberFieldsTest.php index 3026533f..e38c5574 100644 --- a/tests/Integration/Requests/GroupMemberFieldsTest.php +++ b/tests/Integration/Requests/GroupMemberFieldsTest.php @@ -1,9 +1,7 @@ assertEqualsTestData("get_group_fields", "any_other_field.securityLevel", $vocalRangeField->getSecurityLevel()); $this->assertEqualsTestData("get_group_fields", "any_other_field.defaultValue", $vocalRangeField->getDefaultValue()); } -} \ No newline at end of file +} diff --git a/tests/Integration/Requests/GroupMemberRequestTest.php b/tests/Integration/Requests/GroupMemberRequestTest.php index cb88edb2..25aca857 100644 --- a/tests/Integration/Requests/GroupMemberRequestTest.php +++ b/tests/Integration/Requests/GroupMemberRequestTest.php @@ -1,9 +1,7 @@ assertNull($emptyGroupMember->requestPerson()); } -} \ No newline at end of file +} diff --git a/tests/Integration/Requests/GroupRequestTest.php b/tests/Integration/Requests/GroupRequestTest.php index 158968ac..30cfaac9 100644 --- a/tests/Integration/Requests/GroupRequestTest.php +++ b/tests/Integration/Requests/GroupRequestTest.php @@ -1,9 +1,7 @@ assertNull($myGroup->getId()); } -} \ No newline at end of file +} diff --git a/tests/Integration/Requests/GroupTypeRequestTest.php b/tests/Integration/Requests/GroupTypeRequestTest.php index b1b64ed9..b29e1bbd 100644 --- a/tests/Integration/Requests/GroupTypeRequestTest.php +++ b/tests/Integration/Requests/GroupTypeRequestTest.php @@ -9,7 +9,6 @@ class GroupTypeRequestTest extends TestCaseAuthenticated { - private int $groupTypeId1; private int $groupTypeId2; @@ -144,4 +143,4 @@ public function testGetOrderBy_Name() $this->assertTrue($indexGroupType1 > $indexGroupType2); } -} \ No newline at end of file +} diff --git a/tests/Integration/Requests/GroupUpdateRequestTest.php b/tests/Integration/Requests/GroupUpdateRequestTest.php index 0a361655..6865d378 100644 --- a/tests/Integration/Requests/GroupUpdateRequestTest.php +++ b/tests/Integration/Requests/GroupUpdateRequestTest.php @@ -1,15 +1,12 @@ assertEquals($lastYear, $groupMemberReloaded->getMemberStartDate()); $this->assertEquals($nextYear, $groupMemberReloaded->getMemberEndDate()); } -} \ No newline at end of file +} diff --git a/tests/Integration/Requests/PermissionRequestTest.php b/tests/Integration/Requests/PermissionRequestTest.php index 433096e4..c8ed5377 100644 --- a/tests/Integration/Requests/PermissionRequestTest.php +++ b/tests/Integration/Requests/PermissionRequestTest.php @@ -1,15 +1,12 @@ assertEquals($this->churchWiki_EditMasterdata, $globalPermission->getChurchwiki()->getEditMasterdata()); $this->assertEquals($this->churchCheckin_CreatePerson, $globalPermission->getChurchcheckin()->getCreatePerson()); } -} \ No newline at end of file +} diff --git a/tests/Integration/Requests/PersonBirthdayRequestTest.php b/tests/Integration/Requests/PersonBirthdayRequestTest.php index f750c677..65ccc62f 100644 --- a/tests/Integration/Requests/PersonBirthdayRequestTest.php +++ b/tests/Integration/Requests/PersonBirthdayRequestTest.php @@ -1,18 +1,14 @@ assertEquals($this->age, $foundBirthdayChild->getAge()); } -} \ No newline at end of file +} diff --git a/tests/Integration/Requests/PersonRequestTest.php b/tests/Integration/Requests/PersonRequestTest.php index d9ba996f..9981d11c 100644 --- a/tests/Integration/Requests/PersonRequestTest.php +++ b/tests/Integration/Requests/PersonRequestTest.php @@ -11,7 +11,6 @@ use CTApi\Test\Integration\IntegrationTestData; use CTApi\Test\Integration\TestCaseAuthenticated; - class PersonRequestTest extends TestCaseAuthenticated { public function testWhoAmI(): void diff --git a/tests/Integration/Requests/PersonTagRequestTest.php b/tests/Integration/Requests/PersonTagRequestTest.php index 5f8bd73f..c10ff1cc 100644 --- a/tests/Integration/Requests/PersonTagRequestTest.php +++ b/tests/Integration/Requests/PersonTagRequestTest.php @@ -1,17 +1,13 @@ assertNotNull($testTag, "Could not find tag."); $this->assertEquals($this->tagName, $testTag->getName()); } -} \ No newline at end of file +} diff --git a/tests/Integration/Requests/PersonUpdateRequestTest.php b/tests/Integration/Requests/PersonUpdateRequestTest.php index ab19848e..f5a57f93 100644 --- a/tests/Integration/Requests/PersonUpdateRequestTest.php +++ b/tests/Integration/Requests/PersonUpdateRequestTest.php @@ -1,9 +1,7 @@ assertEquals($meReloaded->getBirthName(), $newBirthName); } -} \ No newline at end of file +} diff --git a/tests/Integration/Requests/PublicGroupRequestTest.php b/tests/Integration/Requests/PublicGroupRequestTest.php index 43028435..6027c544 100644 --- a/tests/Integration/Requests/PublicGroupRequestTest.php +++ b/tests/Integration/Requests/PublicGroupRequestTest.php @@ -1,19 +1,15 @@ assertNotNull($imageSmall); $this->assertNotNull($imageWide); } -} \ No newline at end of file +} diff --git a/tests/Integration/Requests/SearchRequestTest.php b/tests/Integration/Requests/SearchRequestTest.php index 566d1209..64f573b3 100644 --- a/tests/Integration/Requests/SearchRequestTest.php +++ b/tests/Integration/Requests/SearchRequestTest.php @@ -1,15 +1,12 @@ assertNull($foundUserResult, "Found result for user with last name " . $this->personLastName . " but expected no result."); } } -} \ No newline at end of file +} diff --git a/tests/Integration/Requests/ServiceRequestTest.php b/tests/Integration/Requests/ServiceRequestTest.php index 052a16bf..d8002ee4 100644 --- a/tests/Integration/Requests/ServiceRequestTest.php +++ b/tests/Integration/Requests/ServiceRequestTest.php @@ -10,10 +10,8 @@ use CTApi\Test\Integration\IntegrationTestData; use CTApi\Test\Integration\TestCaseAuthenticated; - class ServiceRequestTest extends TestCaseAuthenticated { - public function testFindService(): void { $serviceId = IntegrationTestData::getFilter("get_service", "id"); @@ -109,4 +107,4 @@ public function testRequestServicesFromServiceGroup(): void } $this->assertTrue($foundService, "Service could not be retrieved from requestServices-method"); } -} \ No newline at end of file +} diff --git a/tests/Integration/Requests/SongArrangementUpdateRequestTest.php b/tests/Integration/Requests/SongArrangementUpdateRequestTest.php index 5e498424..ab353f43 100644 --- a/tests/Integration/Requests/SongArrangementUpdateRequestTest.php +++ b/tests/Integration/Requests/SongArrangementUpdateRequestTest.php @@ -1,16 +1,13 @@ assertEquals(0, sizeof($allComments)); } -} \ No newline at end of file +} diff --git a/tests/Integration/Requests/SongRequestTest.php b/tests/Integration/Requests/SongRequestTest.php index c27fc169..c8b61fcd 100644 --- a/tests/Integration/Requests/SongRequestTest.php +++ b/tests/Integration/Requests/SongRequestTest.php @@ -9,7 +9,6 @@ use CTApi\Test\Integration\IntegrationTestData; use CTApi\Test\Integration\TestCaseAuthenticated; - class SongRequestTest extends TestCaseAuthenticated { private int $SONG_ID = 0; @@ -133,4 +132,4 @@ public function testSongFilesAndLinks(): void $this->assertInstanceOf(File::class, $file); } } -} \ No newline at end of file +} diff --git a/tests/Integration/Requests/SongStatisticRequestTest.php b/tests/Integration/Requests/SongStatisticRequestTest.php index 3f098f73..114d5662 100644 --- a/tests/Integration/Requests/SongStatisticRequestTest.php +++ b/tests/Integration/Requests/SongStatisticRequestTest.php @@ -1,16 +1,13 @@ assertNotNull($anotherTag); $this->assertEquals($this->anotherTagName, $anotherTag->getName()); } -} \ No newline at end of file +} diff --git a/tests/Integration/Requests/SongUpdateRequestTest.php b/tests/Integration/Requests/SongUpdateRequestTest.php index bfa7397a..607f2ada 100644 --- a/tests/Integration/Requests/SongUpdateRequestTest.php +++ b/tests/Integration/Requests/SongUpdateRequestTest.php @@ -1,15 +1,12 @@ getId() == $this->songTagId){ + foreach($allSongTags as $tag) { + if($tag->getId() == $this->songTagId) { $foundSongTag = $tag; } } @@ -51,8 +49,8 @@ public function testAllPersonTags() $allPersonTags = TagRequest::allPersonTags(); $foundPersonTag = null; - foreach($allPersonTags as $tag){ - if($tag->getId() == $this->personTagId){ + foreach($allPersonTags as $tag) { + if($tag->getId() == $this->personTagId) { $foundPersonTag = $tag; } } @@ -75,8 +73,8 @@ public function testGroupTags() $this->assertNotEmpty($tags); $foundTag = null; - foreach($tags as $tag){ - if($tag->getId() == $searchedTagId){ + foreach($tags as $tag) { + if($tag->getId() == $searchedTagId) { $foundTag = $tag; } } @@ -84,4 +82,4 @@ public function testGroupTags() $this->assertNotNull($foundTag); $this->assertEqualsTestData("get_group", "any_tag.name", $foundTag->getName()); } -} \ No newline at end of file +} diff --git a/tests/Integration/Requests/WikiRequestTest.php b/tests/Integration/Requests/WikiRequestTest.php index f710525e..94a9835f 100644 --- a/tests/Integration/Requests/WikiRequestTest.php +++ b/tests/Integration/Requests/WikiRequestTest.php @@ -10,7 +10,6 @@ use CTApi\Test\Integration\IntegrationTestData; use CTApi\Test\Integration\TestCaseAuthenticated; - class WikiRequestTest extends TestCaseAuthenticated { public function testWikiCategories(): void @@ -207,4 +206,4 @@ public function testWikiMeta(): void $this->assertNotNull($page->getMeta()->getModifiedPerson()->getId()); } -} \ No newline at end of file +} diff --git a/tests/Integration/TestCaseAuthenticated.php b/tests/Integration/TestCaseAuthenticated.php index 50b6de06..182d1c8a 100644 --- a/tests/Integration/TestCaseAuthenticated.php +++ b/tests/Integration/TestCaseAuthenticated.php @@ -15,10 +15,10 @@ public static function setUpBeforeClass(): void { parent::setUpBeforeClass(); - if(self::$configIsInitialized){ - try{ + if(self::$configIsInitialized) { + try { PersonRequest::whoami(); - }catch(CTRequestException $exception){ + } catch(CTRequestException $exception) { self::reauthenticateChurchToolsUser(); } } diff --git a/tests/Unit/CTConfigUnitTest.php b/tests/Unit/CTConfigUnitTest.php index 7754c0f9..d41614c6 100644 --- a/tests/Unit/CTConfigUnitTest.php +++ b/tests/Unit/CTConfigUnitTest.php @@ -9,7 +9,6 @@ class CTConfigUnitTest extends TestCase { - public function setUp(): void { CTConfig::clearConfig(); diff --git a/tests/Unit/CTSessionUnitTest.php b/tests/Unit/CTSessionUnitTest.php index 359d1155..2cf94810 100644 --- a/tests/Unit/CTSessionUnitTest.php +++ b/tests/Unit/CTSessionUnitTest.php @@ -1,9 +1,7 @@ assertEquals(1, sizeof($sessionIds)); $this->assertTrue(in_array("default", $sessionIds)); } -} \ No newline at end of file +} diff --git a/tests/Unit/Cache/CTCacheMiddlewareTest.php b/tests/Unit/Cache/CTCacheMiddlewareTest.php index 7093c66d..13766d91 100644 --- a/tests/Unit/Cache/CTCacheMiddlewareTest.php +++ b/tests/Unit/Cache/CTCacheMiddlewareTest.php @@ -210,4 +210,4 @@ public function invokeCacheMiddleware(RequestInterface $request, $options, $http return $executable($request, $options); } -} \ No newline at end of file +} diff --git a/tests/Unit/Cache/CacheProviderMock.php b/tests/Unit/Cache/CacheProviderMock.php index 38243bb0..dca8f568 100644 --- a/tests/Unit/Cache/CacheProviderMock.php +++ b/tests/Unit/Cache/CacheProviderMock.php @@ -45,4 +45,4 @@ public function resetCount(): void $this->saveTimes = 0; $this->fetchTimes = 0; } -} \ No newline at end of file +} diff --git a/tests/Unit/Docs/AbsenceRequestTest.php b/tests/Unit/Docs/AbsenceRequestTest.php index a7cc8cc3..168b049d 100644 --- a/tests/Unit/Docs/AbsenceRequestTest.php +++ b/tests/Unit/Docs/AbsenceRequestTest.php @@ -1,16 +1,13 @@ assertEquals("db639402f593da794d99aa2706339314da62a7c0dbcc3bb8c505d82d6702b73e", $notNullToken); } -} \ No newline at end of file +} diff --git a/tests/Unit/Docs/CalendarRequestTest.php b/tests/Unit/Docs/CalendarRequestTest.php index 0a04ada3..9797b64b 100644 --- a/tests/Unit/Docs/CalendarRequestTest.php +++ b/tests/Unit/Docs/CalendarRequestTest.php @@ -1,9 +1,7 @@ assertEquals("https://example.church.tools//?q=public/filedownload&id=110&filename=77fd99.pdf", $chordsheetFile?->getFileUrl()); } -} \ No newline at end of file +} diff --git a/tests/Unit/Docs/CombinedAppointmentRequestTest.php b/tests/Unit/Docs/CombinedAppointmentRequestTest.php index e7a5f38e..1aac2368 100644 --- a/tests/Unit/Docs/CombinedAppointmentRequestTest.php +++ b/tests/Unit/Docs/CombinedAppointmentRequestTest.php @@ -7,7 +7,6 @@ class CombinedAppointmentRequestTest extends TestCaseHttpMocked { - public function testCombinedAppointment() { $combinedAppointment = CombinedAppointmentRequest::forAppointment(2, 13, "2023-10-01")->get(); @@ -33,4 +32,4 @@ public function testCombinedAppointment() // see Resource-Model } -} \ No newline at end of file +} diff --git a/tests/Unit/Docs/DBFieldRequestTest.php b/tests/Unit/Docs/DBFieldRequestTest.php index 9f772373..dcf97683 100644 --- a/tests/Unit/Docs/DBFieldRequestTest.php +++ b/tests/Unit/Docs/DBFieldRequestTest.php @@ -1,9 +1,7 @@ assertEquals(20, $dbFieldFirstContact->getLength()); } -} \ No newline at end of file +} diff --git a/tests/Unit/Docs/EventRequestTest.php b/tests/Unit/Docs/EventRequestTest.php index 684a75fe..f7e9eb0a 100644 --- a/tests/Unit/Docs/EventRequestTest.php +++ b/tests/Unit/Docs/EventRequestTest.php @@ -1,9 +1,7 @@ requestService(); $this->assertEquals("Worship-Service", $service?->getName()); } -} \ No newline at end of file +} diff --git a/tests/Unit/Docs/FileRequestTest.php b/tests/Unit/Docs/FileRequestTest.php index 79698737..3f2ebc3d 100644 --- a/tests/Unit/Docs/FileRequestTest.php +++ b/tests/Unit/Docs/FileRequestTest.php @@ -1,6 +1,5 @@ getMember(); // see GroupMember-Model } -} \ No newline at end of file +} diff --git a/tests/Unit/Docs/GroupMemberFieldsTest.php b/tests/Unit/Docs/GroupMemberFieldsTest.php index a73477c2..cb6f551f 100644 --- a/tests/Unit/Docs/GroupMemberFieldsTest.php +++ b/tests/Unit/Docs/GroupMemberFieldsTest.php @@ -1,15 +1,12 @@ get(); @@ -76,4 +73,4 @@ public function testGetFields() $this->assertEquals([], $vocalRangeField->getOptions()); } -} \ No newline at end of file +} diff --git a/tests/Unit/Docs/GroupMemberUpdateRequestTest.php b/tests/Unit/Docs/GroupMemberUpdateRequestTest.php index 99c7b8d6..f7543187 100644 --- a/tests/Unit/Docs/GroupMemberUpdateRequestTest.php +++ b/tests/Unit/Docs/GroupMemberUpdateRequestTest.php @@ -1,15 +1,12 @@ requestGroupImage()?->upload("new-group-image.png"); } -} \ No newline at end of file +} diff --git a/tests/Unit/Docs/GroupTypeRequestTest.php b/tests/Unit/Docs/GroupTypeRequestTest.php index 1a9f6b59..7d73cf1c 100644 --- a/tests/Unit/Docs/GroupTypeRequestTest.php +++ b/tests/Unit/Docs/GroupTypeRequestTest.php @@ -8,7 +8,6 @@ class GroupTypeRequestTest extends TestCaseHttpMocked { - public function testGetAll() { $groupTypes = GroupTypeRequest::all(); @@ -37,4 +36,4 @@ public function testFind() $this->assertEquals(0, $groupType?->getSortKey()); } -} \ No newline at end of file +} diff --git a/tests/Unit/Docs/ModelEventTest.php b/tests/Unit/Docs/ModelEventTest.php index 5efd82bc..14173cda 100644 --- a/tests/Unit/Docs/ModelEventTest.php +++ b/tests/Unit/Docs/ModelEventTest.php @@ -1,16 +1,13 @@ 21]); @@ -31,4 +28,4 @@ public function testRequestMethodPlural() ->orderBy('key') ->get(); } -} \ No newline at end of file +} diff --git a/tests/Unit/Docs/ModelTest.php b/tests/Unit/Docs/ModelTest.php index d94be9db..0c162aab 100644 --- a/tests/Unit/Docs/ModelTest.php +++ b/tests/Unit/Docs/ModelTest.php @@ -1,9 +1,7 @@ assertEquals(21, $this->person->getIdAsInteger()); } -} \ No newline at end of file +} diff --git a/tests/Unit/Docs/PaginationTest.php b/tests/Unit/Docs/PaginationTest.php index d818ccd6..e3463deb 100644 --- a/tests/Unit/Docs/PaginationTest.php +++ b/tests/Unit/Docs/PaginationTest.php @@ -1,15 +1,12 @@ assertEquals(false, $globalPermission->getChurchcheckin()?->getEditMasterdata()); } -} \ No newline at end of file +} diff --git a/tests/Unit/Docs/PersonRequestTest.php b/tests/Unit/Docs/PersonRequestTest.php index af0bb336..5f09f6d1 100644 --- a/tests/Unit/Docs/PersonRequestTest.php +++ b/tests/Unit/Docs/PersonRequestTest.php @@ -1,16 +1,13 @@ assertEquals(21, $musicDirectorTag?->getModifiedBy()); $this->assertEquals("Matthew", $musicDirectorTag?->requestModifier()?->getFirstName()); } -} \ No newline at end of file +} diff --git a/tests/Unit/Docs/PublicGroupRequestTest.php b/tests/Unit/Docs/PublicGroupRequestTest.php index ca45b361..f99b570f 100644 --- a/tests/Unit/Docs/PublicGroupRequestTest.php +++ b/tests/Unit/Docs/PublicGroupRequestTest.php @@ -1,9 +1,7 @@ assertEquals("2020-02-02", $group->getInformation()?->getGroupPlaces()[0]?->getCreatedDate()); $this->assertEquals("2020-02-02 00:00:00", $group->getInformation()?->getGroupPlaces()[0]?->getCreatedDateAsDateTime()?->format("Y-m-d H:i:s")); } -} \ No newline at end of file +} diff --git a/tests/Unit/Docs/ResourceRequestTest.php b/tests/Unit/Docs/ResourceRequestTest.php index b9dcb912..533df2a9 100644 --- a/tests/Unit/Docs/ResourceRequestTest.php +++ b/tests/Unit/Docs/ResourceRequestTest.php @@ -1,9 +1,7 @@ assertEquals("221", $firstBooking->getId()); } -} \ No newline at end of file +} diff --git a/tests/Unit/Docs/SearchRequestTest.php b/tests/Unit/Docs/SearchRequestTest.php index 770b9611..f59c7645 100644 --- a/tests/Unit/Docs/SearchRequestTest.php +++ b/tests/Unit/Docs/SearchRequestTest.php @@ -1,9 +1,7 @@ assertEquals(null, $firstResult->getImageUrl()); $this->assertEquals([], $firstResult->getDomainAttributes()); } -} \ No newline at end of file +} diff --git a/tests/Unit/Docs/ServiceRequestTest.php b/tests/Unit/Docs/ServiceRequestTest.php index 3ab9c8f2..8734e56b 100644 --- a/tests/Unit/Docs/ServiceRequestTest.php +++ b/tests/Unit/Docs/ServiceRequestTest.php @@ -1,6 +1,5 @@ requestServices(); } -} \ No newline at end of file +} diff --git a/tests/Unit/Docs/SongCommentRequestTest.php b/tests/Unit/Docs/SongCommentRequestTest.php index 0b36a875..ba0f1cf4 100644 --- a/tests/Unit/Docs/SongCommentRequestTest.php +++ b/tests/Unit/Docs/SongCommentRequestTest.php @@ -7,7 +7,6 @@ class SongCommentRequestTest extends TestCaseHttpMocked { - public function testGetAllComments() { $comments = SongCommentRequest::getForSongArrangement(2); @@ -46,4 +45,4 @@ public function testDeleteComments() SongCommentRequest::delete($comment->getIdAsInteger()); } -} \ No newline at end of file +} diff --git a/tests/Unit/Docs/SongRequestTest.php b/tests/Unit/Docs/SongRequestTest.php index 97a22e81..de84f02a 100644 --- a/tests/Unit/Docs/SongRequestTest.php +++ b/tests/Unit/Docs/SongRequestTest.php @@ -1,9 +1,7 @@ setName("New Arrangement Title"); SongArrangementRequest::update($arrangement); } -} \ No newline at end of file +} diff --git a/tests/Unit/Docs/SongStatisticRequestTest.php b/tests/Unit/Docs/SongStatisticRequestTest.php index cbfafa28..0b74d300 100644 --- a/tests/Unit/Docs/SongStatisticRequestTest.php +++ b/tests/Unit/Docs/SongStatisticRequestTest.php @@ -1,16 +1,13 @@ assertEquals("5pm Songpool (#5); Youth Songpool (#11); ", $tagList); } -} \ No newline at end of file +} diff --git a/tests/Unit/Docs/WikiRequestTest.php b/tests/Unit/Docs/WikiRequestTest.php index b156dd5b..55cab446 100644 --- a/tests/Unit/Docs/WikiRequestTest.php +++ b/tests/Unit/Docs/WikiRequestTest.php @@ -1,6 +1,5 @@ assertEquals("", $subPages); } -} \ No newline at end of file +} diff --git a/tests/Unit/HttpMock/CTClientMock.php b/tests/Unit/HttpMock/CTClientMock.php index 195a5ceb..2a4e83ce 100644 --- a/tests/Unit/HttpMock/CTClientMock.php +++ b/tests/Unit/HttpMock/CTClientMock.php @@ -12,7 +12,6 @@ class CTClientMock extends CTClient { - private array $requestCalls = []; private array $responses = []; @@ -146,4 +145,4 @@ public function clearAllRequestCalls(): void $this->requestCalls = []; } -} \ No newline at end of file +} diff --git a/tests/Unit/HttpMock/HttpMockDataResolver.php b/tests/Unit/HttpMock/HttpMockDataResolver.php index 991d532e..fe74f359 100644 --- a/tests/Unit/HttpMock/HttpMockDataResolver.php +++ b/tests/Unit/HttpMock/HttpMockDataResolver.php @@ -7,9 +7,9 @@ class HttpMockDataResolver { - const HTTP_DATA_DIR = __DIR__ . '/data/'; + public const HTTP_DATA_DIR = __DIR__ . '/data/'; - static function resolveEndpoint(string $endpoint, array $options = [], string $method = "GET"): array + public static function resolveEndpoint(string $endpoint, array $options = [], string $method = "GET"): array { CTLog::getLog()->debug("HttpMockDataResolver. Resolve endpoint: " . $endpoint); return self::getData($endpoint, $options, $method); @@ -47,13 +47,13 @@ private static function convertEndpointToFileName(string $endpoint, array $optio } // append query and func-name for AJAX-Request - if($endpoint == "index.php"){ + if($endpoint == "index.php") { $q = CTUtil::arrayPathGet($options, "query.q"); - if(!is_null($q)){ + if(!is_null($q)) { $endpoint .= "_q=".$q; } $func = CTUtil::arrayPathGet($options, "json.func"); - if(!is_null($func)){ + if(!is_null($func)) { $endpoint .= "_func=".$func; } } @@ -65,4 +65,4 @@ private static function convertEndpointToFileName(string $endpoint, array $optio CTLog::getLog()->debug("Load file: " . $file); return self::HTTP_DATA_DIR . $file; } -} \ No newline at end of file +} diff --git a/tests/Unit/Models/AbstractModelTest.php b/tests/Unit/Models/AbstractModelTest.php index 526a7a22..d68ea07b 100644 --- a/tests/Unit/Models/AbstractModelTest.php +++ b/tests/Unit/Models/AbstractModelTest.php @@ -1,9 +1,7 @@ id = $id; return $this; } -} \ No newline at end of file +} diff --git a/tests/Unit/Models/AppointmentModelTest.php b/tests/Unit/Models/AppointmentModelTest.php index 20b8bd5e..0bfdffbb 100644 --- a/tests/Unit/Models/AppointmentModelTest.php +++ b/tests/Unit/Models/AppointmentModelTest.php @@ -8,7 +8,6 @@ class AppointmentModelTest extends TestCase { - public function testProcessBaseAttributes() { $dataA = [ @@ -114,4 +113,4 @@ public function testToData() $this->assertArrayHasKey("startDate", $data); $this->assertArrayHasKey("endDate", $data); } -} \ No newline at end of file +} diff --git a/tests/Unit/Models/DBFieldsTraitTest.php b/tests/Unit/Models/DBFieldsTraitTest.php index 27fc0bda..ccb19add 100644 --- a/tests/Unit/Models/DBFieldsTraitTest.php +++ b/tests/Unit/Models/DBFieldsTraitTest.php @@ -1,9 +1,7 @@ 21, 'name' => "Robin Hood", 'age' => 32 ]; - const DATA_LIST = [ + public const DATA_LIST = [ ['id' => 22, 'name' => "Big James", 'age' => 94], ['id' => 23, 'name' => "Little John", 'age' => 23], ['id' => 24, 'name' => "Joe", 'age' => 32], @@ -64,4 +63,4 @@ class ModelMock public int $id; public string $name; -} \ No newline at end of file +} diff --git a/tests/Unit/Models/FillWithDataTraitToData.php b/tests/Unit/Models/FillWithDataTraitToData.php index 137bf482..28d53c5c 100644 --- a/tests/Unit/Models/FillWithDataTraitToData.php +++ b/tests/Unit/Models/FillWithDataTraitToData.php @@ -1,9 +1,7 @@ assertIsArray($lastArrangement); $this->assertEquals("221", $lastArrangement["id"]); } -} \ No newline at end of file +} diff --git a/tests/Unit/Models/FillWithDataTraitTypeMissmatchTest.php b/tests/Unit/Models/FillWithDataTraitTypeMissmatchTest.php index 704c2ef5..6cb68180 100644 --- a/tests/Unit/Models/FillWithDataTraitTypeMissmatchTest.php +++ b/tests/Unit/Models/FillWithDataTraitTypeMissmatchTest.php @@ -1,9 +1,7 @@ null */ - const TYPE_STRING = 0; - const TYPE_INT = 1; - const TYPE_ARRAY = 2; - const TYPE_CLASS = 3; - const TYPE_NULL = 4; - const TYPE_NONE = 5; - const TYPE_BOOL = 6; - const TYPE_FLOAT = 7; + public const TYPE_STRING = 0; + public const TYPE_INT = 1; + public const TYPE_ARRAY = 2; + public const TYPE_CLASS = 3; + public const TYPE_NULL = 4; + public const TYPE_NONE = 5; + public const TYPE_BOOL = 6; + public const TYPE_FLOAT = 7; /** * Test: String @@ -407,7 +405,6 @@ public function testFloatToFloat() class Movie { - use FillWithData; protected ?int $id = null; @@ -506,4 +503,4 @@ public function setName(?string $name): Actor $this->name = $name; return $this; } -} \ No newline at end of file +} diff --git a/tests/Unit/Models/GroupInformationTest.php b/tests/Unit/Models/GroupInformationTest.php index f6408dad..5221d4bc 100644 --- a/tests/Unit/Models/GroupInformationTest.php +++ b/tests/Unit/Models/GroupInformationTest.php @@ -1,15 +1,12 @@ assertArrayHasKey("imageUrlBanner", $data); $this->assertEquals($data["imageUrlBanner"], $this->imageUrlBanner); } -} \ No newline at end of file +} diff --git a/tests/Unit/Models/PublicGroupTest.php b/tests/Unit/Models/PublicGroupTest.php index 37a9742a..30333139 100644 --- a/tests/Unit/Models/PublicGroupTest.php +++ b/tests/Unit/Models/PublicGroupTest.php @@ -1,16 +1,13 @@ assertEquals("https://test.church.tools/publicgroup/21?hash=EXAMPLEHASHCODE", $publicGroup->generateRegistrationLink("EXAMPLEHASHCODE")); } -} \ No newline at end of file +} diff --git a/tests/Unit/Models/SongArrangementTest.php b/tests/Unit/Models/SongArrangementTest.php index d05ef9a7..c238557c 100644 --- a/tests/Unit/Models/SongArrangementTest.php +++ b/tests/Unit/Models/SongArrangementTest.php @@ -7,7 +7,6 @@ class SongArrangementTest extends TestCase { - private SongArrangement $EMPTY_ARRANGEMENT; private SongArrangement $FULL_ARRANGEMENT; @@ -72,4 +71,4 @@ public function testGetFirstLink(): void $this->assertEquals("https://multitracks.com/path/to/song", $multiTracksLink?->getFileUrl()); } -} \ No newline at end of file +} diff --git a/tests/Unit/Models/SongStatisticTest.php b/tests/Unit/Models/SongStatisticTest.php index c1ccd4f3..9b680e3b 100644 --- a/tests/Unit/Models/SongStatisticTest.php +++ b/tests/Unit/Models/SongStatisticTest.php @@ -1,9 +1,7 @@ assertEquals(4, $data["count"]); } -} \ No newline at end of file +} diff --git a/tests/Unit/Models/Traits/ExtractDataTest.php b/tests/Unit/Models/Traits/ExtractDataTest.php index 1bad57f0..353489af 100644 --- a/tests/Unit/Models/Traits/ExtractDataTest.php +++ b/tests/Unit/Models/Traits/ExtractDataTest.php @@ -42,4 +42,4 @@ public function __construct(string $firstName, string $lastName, int $age) $this->lastName = $lastName; $this->age = $age; } -} \ No newline at end of file +} diff --git a/tests/Unit/Models/WikiTreeTest.php b/tests/Unit/Models/WikiTreeTest.php index bc574a47..8374c737 100644 --- a/tests/Unit/Models/WikiTreeTest.php +++ b/tests/Unit/Models/WikiTreeTest.php @@ -77,4 +77,4 @@ public function testSpecialUmlauteSupport(): void $this->assertEquals($subPage, $rootPageNode->getChildNodes()[0]->getWikiPage()); } -} \ No newline at end of file +} diff --git a/tests/Unit/Requests/EventRequestUnitTest.php b/tests/Unit/Requests/EventRequestUnitTest.php index 0d19e58e..eebda19c 100644 --- a/tests/Unit/Requests/EventRequestUnitTest.php +++ b/tests/Unit/Requests/EventRequestUnitTest.php @@ -7,7 +7,6 @@ class EventRequestUnitTest extends TestCaseHttpMocked { - public function testGetAllEvents(): void { $allEvents = EventRequest::all(); @@ -25,4 +24,4 @@ public function testGetEvent(): void } -} \ No newline at end of file +} diff --git a/tests/Unit/Requests/OrderByConditionTest.php b/tests/Unit/Requests/OrderByConditionTest.php index 216fe570..8668868d 100644 --- a/tests/Unit/Requests/OrderByConditionTest.php +++ b/tests/Unit/Requests/OrderByConditionTest.php @@ -8,7 +8,6 @@ class OrderByConditionTest extends TestCase { - protected RequestBuilder $exampleRequestBuilder; protected array $data = [ ["id" => 21, "name" => "Joe", "tags" => [21, 23, 42]], @@ -125,4 +124,4 @@ public function orderMyData(&$data): void { $this->orderRawData($data); } -} \ No newline at end of file +} diff --git a/tests/Unit/Requests/PaginationTest.php b/tests/Unit/Requests/PaginationTest.php index b4f2ffa6..24a64acc 100644 --- a/tests/Unit/Requests/PaginationTest.php +++ b/tests/Unit/Requests/PaginationTest.php @@ -1,16 +1,13 @@ assertArrayHasKey("limit", $request["options"]["query"]); $this->assertEquals($pageSize, $request["options"]["query"]["limit"]); } -} \ No newline at end of file +} diff --git a/tests/Unit/Requests/PersonRequestBuilderCreateTest.php b/tests/Unit/Requests/PersonRequestBuilderCreateTest.php index 41e174d1..6a846ccf 100644 --- a/tests/Unit/Requests/PersonRequestBuilderCreateTest.php +++ b/tests/Unit/Requests/PersonRequestBuilderCreateTest.php @@ -1,9 +1,7 @@ should be ignored ]; } -} \ No newline at end of file +} diff --git a/tests/Unit/Requests/SongStatisticRequestLazyTest.php b/tests/Unit/Requests/SongStatisticRequestLazyTest.php index 2650e450..b2dba0b1 100644 --- a/tests/Unit/Requests/SongStatisticRequestLazyTest.php +++ b/tests/Unit/Requests/SongStatisticRequestLazyTest.php @@ -1,9 +1,7 @@ fail("CTClient is not the CTClientMock"); } } -} \ No newline at end of file +} diff --git a/tests/Unit/Requests/WhereConditionTest.php b/tests/Unit/Requests/WhereConditionTest.php index 896cb020..7e9a7f9f 100644 --- a/tests/Unit/Requests/WhereConditionTest.php +++ b/tests/Unit/Requests/WhereConditionTest.php @@ -8,7 +8,6 @@ class WhereConditionTest extends TestCase { - public function testNoDoubleWhereClauses(): void { $exampleRequest = new ExampleRequest(); @@ -21,4 +20,4 @@ public function testNoDoubleWhereClauses(): void class ExampleRequest { use WhereCondition; -} \ No newline at end of file +} diff --git a/tests/Unit/TestCaseHttpMocked.php b/tests/Unit/TestCaseHttpMocked.php index 4d187b54..5af36956 100644 --- a/tests/Unit/TestCaseHttpMocked.php +++ b/tests/Unit/TestCaseHttpMocked.php @@ -51,4 +51,4 @@ protected function tearDown(): void $client = CTClient::createClient(); CTClient::setClient($client); } -} \ No newline at end of file +} diff --git a/tests/Unit/Utils/CTDateTimeServiceTest.php b/tests/Unit/Utils/CTDateTimeServiceTest.php index 513b82a5..45a3fdb6 100644 --- a/tests/Unit/Utils/CTDateTimeServiceTest.php +++ b/tests/Unit/Utils/CTDateTimeServiceTest.php @@ -1,9 +1,7 @@ exampleArray, 'fake.age', 21); $this->assertEquals(21, $this->exampleArray['fake']['age']); } -} \ No newline at end of file +}