From 48b234339b9827c518615dbb8f287db34876f82b Mon Sep 17 00:00:00 2001 From: Daniel Karbach Date: Mon, 2 Sep 2024 12:51:55 +0200 Subject: [PATCH 01/16] switch broadcasting to reverb --- composer.json | 2 +- composer.lock | 517 +++++++++++++++++++------------------- config/broadcasting.php | 16 ++ config/reverb.php | 91 +++++++ package-lock.json | 2 +- package.json | 2 +- resources/js/bootstrap.js | 5 +- 7 files changed, 372 insertions(+), 263 deletions(-) create mode 100644 config/reverb.php diff --git a/composer.json b/composer.json index 5075d26..02ce852 100644 --- a/composer.json +++ b/composer.json @@ -6,12 +6,12 @@ "license": "MIT", "require": { "php": "^8.1", - "beyondcode/laravel-websockets": "^1.13", "doctrine/dbal": "^3.3", "guzzlehttp/guzzle": "^7.2", "jakyeru/larascord": "^3.0", "laravel/breeze": "^1.4", "laravel/framework": "^10.0", + "laravel/reverb": "^1.2", "laravel/sanctum": "^3.2", "laravel/tinker": "^2.7", "laravel/ui": "^4.0", diff --git a/composer.lock b/composer.lock index 78d13b4..702f96d 100644 --- a/composer.lock +++ b/composer.lock @@ -4,91 +4,8 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "This file is @generated automatically" ], - "content-hash": "9f3035a68ea28a4f87fd5c8433bb5464", + "content-hash": "7bd49e915d879427a2aadc5a2101fcb4", "packages": [ - { - "name": "beyondcode/laravel-websockets", - "version": "1.14.1", - "source": { - "type": "git", - "url": "https://github.com/beyondcode/laravel-websockets.git", - "reference": "fee9a81e42a096d2aaca216ce91acf6e25d8c06d" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/beyondcode/laravel-websockets/zipball/fee9a81e42a096d2aaca216ce91acf6e25d8c06d", - "reference": "fee9a81e42a096d2aaca216ce91acf6e25d8c06d", - "shasum": "" - }, - "require": { - "cboden/ratchet": "^0.4.1", - "ext-json": "*", - "facade/ignition-contracts": "^1.0", - "guzzlehttp/psr7": "^1.7|^2.0", - "illuminate/broadcasting": "^6.0|^7.0|^8.0|^9.0|^10.0", - "illuminate/console": "^6.0|^7.0|^8.0|^9.0|^10.0", - "illuminate/http": "^6.0|^7.0|^8.0|^9.0|^10.0", - "illuminate/routing": "^6.0|^7.0|^8.0|^9.0|^10.0", - "illuminate/support": "^6.0|^7.0|^8.0|^9.0|^10.0", - "php": "^7.2|^8.0", - "pusher/pusher-php-server": "^3.0|^4.0|^5.0|^6.0|^7.0", - "react/dns": "^1.1", - "react/http": "^1.1", - "symfony/http-kernel": "^4.0|^5.0|^6.0", - "symfony/psr-http-message-bridge": "^1.1|^2.0" - }, - "require-dev": { - "mockery/mockery": "^1.3.3", - "orchestra/testbench": "^4.0|^5.0|^6.0|^7.0|^8.0", - "phpunit/phpunit": "^8.0|^9.0|^10.0" - }, - "type": "library", - "extra": { - "laravel": { - "providers": [ - "BeyondCode\\LaravelWebSockets\\WebSocketsServiceProvider" - ], - "aliases": { - "WebSocketRouter": "BeyondCode\\LaravelWebSockets\\Facades\\WebSocketRouter" - } - } - }, - "autoload": { - "psr-4": { - "BeyondCode\\LaravelWebSockets\\": "src" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Marcel Pociot", - "email": "marcel@beyondco.de", - "homepage": "https://beyondcode.de", - "role": "Developer" - }, - { - "name": "Freek Van der Herten", - "email": "freek@spatie.be", - "homepage": "https://spatie.be", - "role": "Developer" - } - ], - "description": "An easy to use WebSocket server", - "homepage": "https://github.com/beyondcode/laravel-websockets", - "keywords": [ - "beyondcode", - "laravel-websockets" - ], - "support": { - "issues": "https://github.com/beyondcode/laravel-websockets/issues", - "source": "https://github.com/beyondcode/laravel-websockets/tree/1.14.1" - }, - "abandoned": true, - "time": "2023-08-30T07:23:12+00:00" - }, { "name": "brick/math", "version": "0.12.1", @@ -219,35 +136,29 @@ "time": "2023-12-11T17:09:12+00:00" }, { - "name": "cboden/ratchet", - "version": "v0.4.4", + "name": "clue/redis-protocol", + "version": "v0.3.2", "source": { "type": "git", - "url": "https://github.com/ratchetphp/Ratchet.git", - "reference": "5012dc954541b40c5599d286fd40653f5716a38f" + "url": "https://github.com/clue/redis-protocol.git", + "reference": "6f565332f5531b7722d1e9c445314b91862f6d6c" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/ratchetphp/Ratchet/zipball/5012dc954541b40c5599d286fd40653f5716a38f", - "reference": "5012dc954541b40c5599d286fd40653f5716a38f", + "url": "https://api.github.com/repos/clue/redis-protocol/zipball/6f565332f5531b7722d1e9c445314b91862f6d6c", + "reference": "6f565332f5531b7722d1e9c445314b91862f6d6c", "shasum": "" }, "require": { - "guzzlehttp/psr7": "^1.7|^2.0", - "php": ">=5.4.2", - "ratchet/rfc6455": "^0.3.1", - "react/event-loop": ">=0.4", - "react/socket": "^1.0 || ^0.8 || ^0.7 || ^0.6 || ^0.5", - "symfony/http-foundation": "^2.6|^3.0|^4.0|^5.0|^6.0", - "symfony/routing": "^2.6|^3.0|^4.0|^5.0|^6.0" + "php": ">=5.3" }, "require-dev": { - "phpunit/phpunit": "~4.8" + "phpunit/phpunit": "^9.6 || ^5.7 || ^4.8.36" }, "type": "library", "autoload": { "psr-4": { - "Ratchet\\": "src/Ratchet" + "Clue\\Redis\\Protocol\\": "src/" } }, "notification-url": "https://packagist.org/downloads/", @@ -256,30 +167,103 @@ ], "authors": [ { - "name": "Chris Boden", - "email": "cboden@gmail.com", - "role": "Developer" + "name": "Christian Lück", + "email": "christian@lueck.tv" + } + ], + "description": "A streaming Redis protocol (RESP) parser and serializer written in pure PHP.", + "homepage": "https://github.com/clue/redis-protocol", + "keywords": [ + "parser", + "protocol", + "redis", + "resp", + "serializer", + "streaming" + ], + "support": { + "issues": "https://github.com/clue/redis-protocol/issues", + "source": "https://github.com/clue/redis-protocol/tree/v0.3.2" + }, + "funding": [ + { + "url": "https://clue.engineering/support", + "type": "custom" }, { - "name": "Matt Bonneau", - "role": "Developer" + "url": "https://github.com/clue", + "type": "github" } ], - "description": "PHP WebSocket library", - "homepage": "http://socketo.me", + "time": "2024-08-07T11:06:28+00:00" + }, + { + "name": "clue/redis-react", + "version": "v2.7.0", + "source": { + "type": "git", + "url": "https://github.com/clue/reactphp-redis.git", + "reference": "2283690f249e8d93342dd63b5285732d2654e077" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/clue/reactphp-redis/zipball/2283690f249e8d93342dd63b5285732d2654e077", + "reference": "2283690f249e8d93342dd63b5285732d2654e077", + "shasum": "" + }, + "require": { + "clue/redis-protocol": "0.3.*", + "evenement/evenement": "^3.0 || ^2.0 || ^1.0", + "php": ">=5.3", + "react/event-loop": "^1.2", + "react/promise": "^3 || ^2.0 || ^1.1", + "react/promise-timer": "^1.9", + "react/socket": "^1.12" + }, + "require-dev": { + "clue/block-react": "^1.5", + "phpunit/phpunit": "^9.6 || ^5.7 || ^4.8.36" + }, + "type": "library", + "autoload": { + "psr-4": { + "Clue\\React\\Redis\\": "src/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Christian Lück", + "email": "christian@clue.engineering" + } + ], + "description": "Async Redis client implementation, built on top of ReactPHP.", + "homepage": "https://github.com/clue/reactphp-redis", "keywords": [ - "Ratchet", - "WebSockets", - "server", - "sockets", - "websocket" + "async", + "client", + "database", + "reactphp", + "redis" ], "support": { - "chat": "https://gitter.im/reactphp/reactphp", - "issues": "https://github.com/ratchetphp/Ratchet/issues", - "source": "https://github.com/ratchetphp/Ratchet/tree/v0.4.4" + "issues": "https://github.com/clue/reactphp-redis/issues", + "source": "https://github.com/clue/reactphp-redis/tree/v2.7.0" }, - "time": "2021-12-14T00:20:41+00:00" + "funding": [ + { + "url": "https://clue.engineering/support", + "type": "custom" + }, + { + "url": "https://github.com/clue", + "type": "github" + } + ], + "time": "2024-01-05T15:54:20+00:00" }, { "name": "dflydev/dot-access-data", @@ -1144,59 +1128,6 @@ }, "time": "2023-08-08T05:53:35+00:00" }, - { - "name": "facade/ignition-contracts", - "version": "1.0.2", - "source": { - "type": "git", - "url": "https://github.com/facade/ignition-contracts.git", - "reference": "3c921a1cdba35b68a7f0ccffc6dffc1995b18267" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/facade/ignition-contracts/zipball/3c921a1cdba35b68a7f0ccffc6dffc1995b18267", - "reference": "3c921a1cdba35b68a7f0ccffc6dffc1995b18267", - "shasum": "" - }, - "require": { - "php": "^7.3|^8.0" - }, - "require-dev": { - "friendsofphp/php-cs-fixer": "^v2.15.8", - "phpunit/phpunit": "^9.3.11", - "vimeo/psalm": "^3.17.1" - }, - "type": "library", - "autoload": { - "psr-4": { - "Facade\\IgnitionContracts\\": "src" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Freek Van der Herten", - "email": "freek@spatie.be", - "homepage": "https://flareapp.io", - "role": "Developer" - } - ], - "description": "Solution contracts for Ignition", - "homepage": "https://github.com/facade/ignition-contracts", - "keywords": [ - "contracts", - "flare", - "ignition" - ], - "support": { - "issues": "https://github.com/facade/ignition-contracts/issues", - "source": "https://github.com/facade/ignition-contracts/tree/1.0.2" - }, - "time": "2020-10-16T08:27:54+00:00" - }, { "name": "fig/http-message-util", "version": "1.1.5", @@ -2174,6 +2105,88 @@ }, "time": "2024-08-12T22:06:33+00:00" }, + { + "name": "laravel/reverb", + "version": "v1.2.0", + "source": { + "type": "git", + "url": "https://github.com/laravel/reverb.git", + "reference": "d4993bc6b8664d439c1c7d248bd25ef371e532cf" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/laravel/reverb/zipball/d4993bc6b8664d439c1c7d248bd25ef371e532cf", + "reference": "d4993bc6b8664d439c1c7d248bd25ef371e532cf", + "shasum": "" + }, + "require": { + "clue/redis-react": "^2.6", + "guzzlehttp/psr7": "^2.6", + "illuminate/console": "^10.47|^11.0", + "illuminate/contracts": "^10.47|^11.0", + "illuminate/http": "^10.47|^11.0", + "illuminate/support": "^10.47|^11.0", + "laravel/prompts": "^0.1.15", + "php": "^8.2", + "pusher/pusher-php-server": "^7.2", + "ratchet/rfc6455": "^0.3.1", + "react/promise-timer": "^1.10", + "react/socket": "^1.14", + "symfony/console": "^6.0|^7.0", + "symfony/http-foundation": "^6.3|^7.0" + }, + "require-dev": { + "orchestra/testbench": "^8.0|^9.0", + "pestphp/pest": "^2.0", + "phpstan/phpstan": "^1.10", + "ratchet/pawl": "^0.4.1", + "react/async": "^4.2", + "react/http": "^1.9" + }, + "type": "library", + "extra": { + "laravel": { + "providers": [ + "Laravel\\Reverb\\ApplicationManagerServiceProvider", + "Laravel\\Reverb\\ReverbServiceProvider" + ], + "aliases": { + "Output": "Laravel\\Reverb\\Output" + } + } + }, + "autoload": { + "psr-4": { + "Laravel\\Reverb\\": "src/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Taylor Otwell", + "email": "taylor@laravel.com" + }, + { + "name": "Joe Dixon", + "email": "joe@laravel.com" + } + ], + "description": "Laravel Reverb provides a real-time WebSocket communication backend for Laravel applications.", + "keywords": [ + "WebSockets", + "laravel", + "real-time", + "websocket" + ], + "support": { + "issues": "https://github.com/laravel/reverb/issues", + "source": "https://github.com/laravel/reverb/tree/v1.2.0" + }, + "time": "2024-08-16T17:59:50+00:00" + }, { "name": "laravel/sanctum", "version": "v3.3.3", @@ -5118,6 +5131,85 @@ ], "time": "2023-11-16T16:16:50+00:00" }, + { + "name": "react/promise-timer", + "version": "v1.11.0", + "source": { + "type": "git", + "url": "https://github.com/reactphp/promise-timer.git", + "reference": "4f70306ed66b8b44768941ca7f142092600fafc1" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/reactphp/promise-timer/zipball/4f70306ed66b8b44768941ca7f142092600fafc1", + "reference": "4f70306ed66b8b44768941ca7f142092600fafc1", + "shasum": "" + }, + "require": { + "php": ">=5.3", + "react/event-loop": "^1.2", + "react/promise": "^3.2 || ^2.7.0 || ^1.2.1" + }, + "require-dev": { + "phpunit/phpunit": "^9.6 || ^5.7 || ^4.8.36" + }, + "type": "library", + "autoload": { + "files": [ + "src/functions_include.php" + ], + "psr-4": { + "React\\Promise\\Timer\\": "src/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Christian Lück", + "email": "christian@clue.engineering", + "homepage": "https://clue.engineering/" + }, + { + "name": "Cees-Jan Kiewiet", + "email": "reactphp@ceesjankiewiet.nl", + "homepage": "https://wyrihaximus.net/" + }, + { + "name": "Jan Sorgalla", + "email": "jsorgalla@gmail.com", + "homepage": "https://sorgalla.com/" + }, + { + "name": "Chris Boden", + "email": "cboden@gmail.com", + "homepage": "https://cboden.dev/" + } + ], + "description": "A trivial implementation of timeouts for Promises, built on top of ReactPHP.", + "homepage": "https://github.com/reactphp/promise-timer", + "keywords": [ + "async", + "event-loop", + "promise", + "reactphp", + "timeout", + "timer" + ], + "support": { + "issues": "https://github.com/reactphp/promise-timer/issues", + "source": "https://github.com/reactphp/promise-timer/tree/v1.11.0" + }, + "funding": [ + { + "url": "https://opencollective.com/reactphp", + "type": "open_collective" + } + ], + "time": "2024-06-04T14:27:45+00:00" + }, { "name": "react/socket", "version": "v1.16.0", @@ -6991,95 +7083,6 @@ ], "time": "2024-05-31T14:49:08+00:00" }, - { - "name": "symfony/psr-http-message-bridge", - "version": "v2.3.1", - "source": { - "type": "git", - "url": "https://github.com/symfony/psr-http-message-bridge.git", - "reference": "581ca6067eb62640de5ff08ee1ba6850a0ee472e" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/symfony/psr-http-message-bridge/zipball/581ca6067eb62640de5ff08ee1ba6850a0ee472e", - "reference": "581ca6067eb62640de5ff08ee1ba6850a0ee472e", - "shasum": "" - }, - "require": { - "php": ">=7.2.5", - "psr/http-message": "^1.0 || ^2.0", - "symfony/deprecation-contracts": "^2.5 || ^3.0", - "symfony/http-foundation": "^5.4 || ^6.0" - }, - "require-dev": { - "nyholm/psr7": "^1.1", - "psr/log": "^1.1 || ^2 || ^3", - "symfony/browser-kit": "^5.4 || ^6.0", - "symfony/config": "^5.4 || ^6.0", - "symfony/event-dispatcher": "^5.4 || ^6.0", - "symfony/framework-bundle": "^5.4 || ^6.0", - "symfony/http-kernel": "^5.4 || ^6.0", - "symfony/phpunit-bridge": "^6.2" - }, - "suggest": { - "nyholm/psr7": "For a super lightweight PSR-7/17 implementation" - }, - "type": "symfony-bridge", - "extra": { - "branch-alias": { - "dev-main": "2.3-dev" - } - }, - "autoload": { - "psr-4": { - "Symfony\\Bridge\\PsrHttpMessage\\": "" - }, - "exclude-from-classmap": [ - "/Tests/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Fabien Potencier", - "email": "fabien@symfony.com" - }, - { - "name": "Symfony Community", - "homepage": "http://symfony.com/contributors" - } - ], - "description": "PSR HTTP message bridge", - "homepage": "http://symfony.com", - "keywords": [ - "http", - "http-message", - "psr-17", - "psr-7" - ], - "support": { - "issues": "https://github.com/symfony/psr-http-message-bridge/issues", - "source": "https://github.com/symfony/psr-http-message-bridge/tree/v2.3.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-07-26T11:53:26+00:00" - }, { "name": "symfony/routing", "version": "v6.4.11", diff --git a/config/broadcasting.php b/config/broadcasting.php index fcedd9f..7d0646c 100644 --- a/config/broadcasting.php +++ b/config/broadcasting.php @@ -30,6 +30,22 @@ return [ 'connections' => [ + 'reverb' => [ + 'driver' => 'reverb', + 'key' => env('REVERB_APP_KEY'), + 'secret' => env('REVERB_APP_SECRET'), + 'app_id' => env('REVERB_APP_ID'), + 'options' => [ + 'host' => env('REVERB_HOST'), + 'port' => env('REVERB_PORT', 443), + 'scheme' => env('REVERB_SCHEME', 'https'), + 'useTLS' => env('REVERB_SCHEME', 'https') === 'https', + ], + 'client_options' => [ + // Guzzle client options: https://docs.guzzlephp.org/en/stable/request-options.html + ], + ], + 'pusher' => [ 'driver' => 'pusher', 'key' => env('PUSHER_APP_KEY'), diff --git a/config/reverb.php b/config/reverb.php new file mode 100644 index 0000000..798ead6 --- /dev/null +++ b/config/reverb.php @@ -0,0 +1,91 @@ + env('REVERB_SERVER', 'reverb'), + + /* + |-------------------------------------------------------------------------- + | Reverb Servers + |-------------------------------------------------------------------------- + | + | Here you may define details for each of the supported Reverb servers. + | Each server has its own configuration options that are defined in + | the array below. You should ensure all the options are present. + | + */ + + 'servers' => [ + + 'reverb' => [ + 'host' => env('REVERB_SERVER_HOST', '0.0.0.0'), + 'port' => env('REVERB_SERVER_PORT', 8080), + 'hostname' => env('REVERB_HOST'), + 'options' => [ + 'tls' => [], + ], + 'max_request_size' => env('REVERB_MAX_REQUEST_SIZE', 10_000), + 'scaling' => [ + 'enabled' => env('REVERB_SCALING_ENABLED', false), + 'channel' => env('REVERB_SCALING_CHANNEL', 'reverb'), + 'server' => [ + 'url' => env('REDIS_URL'), + 'host' => env('REDIS_HOST', '127.0.0.1'), + 'port' => env('REDIS_PORT', '6379'), + 'username' => env('REDIS_USERNAME'), + 'password' => env('REDIS_PASSWORD'), + 'database' => env('REDIS_DB', '0'), + ], + ], + 'pulse_ingest_interval' => env('REVERB_PULSE_INGEST_INTERVAL', 15), + 'telescope_ingest_interval' => env('REVERB_TELESCOPE_INGEST_INTERVAL', 15), + ], + + ], + + /* + |-------------------------------------------------------------------------- + | Reverb Applications + |-------------------------------------------------------------------------- + | + | Here you may define how Reverb applications are managed. If you choose + | to use the "config" provider, you may define an array of apps which + | your server will support, including their connection credentials. + | + */ + + 'apps' => [ + + 'provider' => 'config', + + 'apps' => [ + [ + 'key' => env('REVERB_APP_KEY'), + 'secret' => env('REVERB_APP_SECRET'), + 'app_id' => env('REVERB_APP_ID'), + 'options' => [ + 'host' => env('REVERB_HOST'), + 'port' => env('REVERB_PORT', 443), + 'scheme' => env('REVERB_SCHEME', 'https'), + 'useTLS' => env('REVERB_SCHEME', 'https') === 'https', + ], + 'allowed_origins' => ['*'], + 'ping_interval' => env('REVERB_APP_PING_INTERVAL', 60), + 'max_message_size' => env('REVERB_APP_MAX_MESSAGE_SIZE', 10_000), + ], + ], + + ], + +]; diff --git a/package-lock.json b/package-lock.json index 95b2603..0885cc4 100644 --- a/package-lock.json +++ b/package-lock.json @@ -20,7 +20,7 @@ "formik": "^2.2.9", "i18next": "^23.4.9", "i18next-browser-languagedetector": "^8.0.0", - "laravel-echo": "^1.11.3", + "laravel-echo": "^1.16.1", "localforage": "^1.10.0", "moment": "^2.29.1", "numeral": "^2.0.6", diff --git a/package.json b/package.json index 76d0f93..32f9e0d 100644 --- a/package.json +++ b/package.json @@ -138,7 +138,7 @@ "formik": "^2.2.9", "i18next": "^23.4.9", "i18next-browser-languagedetector": "^8.0.0", - "laravel-echo": "^1.11.3", + "laravel-echo": "^1.16.1", "localforage": "^1.10.0", "moment": "^2.29.1", "numeral": "^2.0.6", diff --git a/resources/js/bootstrap.js b/resources/js/bootstrap.js index cffa4cb..27a32b4 100644 --- a/resources/js/bootstrap.js +++ b/resources/js/bootstrap.js @@ -30,9 +30,8 @@ import Echo from 'laravel-echo'; window.Pusher = require('pusher-js'); window.Echo = new Echo({ - broadcaster: 'pusher', - key: process.env.MIX_PUSHER_APP_KEY, - cluster: process.env.MIX_PUSHER_APP_CLUSTER, + broadcaster: 'reverb', + key: process.env.MIX_REVERB_APP_KEY, wsHost: window.location.hostname, wsPort: window.location.port, forceTLS: false, -- 2.39.2 From ed789bb25397746cc75656415acf1bce93f39b4f Mon Sep 17 00:00:00 2001 From: Daniel Karbach Date: Mon, 2 Sep 2024 13:12:49 +0200 Subject: [PATCH 02/16] upgrade laravel to v11 --- .gitignore | 1 + composer.json | 10 +- composer.lock | 1173 ++++++++++------------- phpunit.xml | 54 +- tests/Unit/TwitchBot/IRCMessageTest.php | 6 +- 5 files changed, 566 insertions(+), 678 deletions(-) diff --git a/.gitignore b/.gitignore index 39965bf..ca35555 100644 --- a/.gitignore +++ b/.gitignore @@ -16,6 +16,7 @@ .env .env.backup .env.testing +.phpunit.cache .phpunit.result.cache docker-compose.override.yml Homestead.json diff --git a/composer.json b/composer.json index 02ce852..4a8569c 100644 --- a/composer.json +++ b/composer.json @@ -9,10 +9,10 @@ "doctrine/dbal": "^3.3", "guzzlehttp/guzzle": "^7.2", "jakyeru/larascord": "^3.0", - "laravel/breeze": "^1.4", - "laravel/framework": "^10.0", + "laravel/breeze": "^2.0", + "laravel/framework": "^11.0", "laravel/reverb": "^1.2", - "laravel/sanctum": "^3.2", + "laravel/sanctum": "^4.0", "laravel/tinker": "^2.7", "laravel/ui": "^4.0", "patrickschur/language-detection": "^5.3", @@ -23,8 +23,8 @@ "fakerphp/faker": "^1.9.1", "laravel/sail": "^1.0.1", "mockery/mockery": "^1.4.4", - "nunomaduro/collision": "^6.1", - "phpunit/phpunit": "^9.5.10", + "nunomaduro/collision": "^8.1", + "phpunit/phpunit": "^11.0", "spatie/laravel-ignition": "^2.0" }, "autoload": { diff --git a/composer.lock b/composer.lock index 702f96d..9f1ff9e 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": "7bd49e915d879427a2aadc5a2101fcb4", + "content-hash": "79d306d3125d944d59bac955ffb58da5", "packages": [ { "name": "brick/math", @@ -1780,34 +1780,32 @@ }, { "name": "laravel/breeze", - "version": "v1.29.1", + "version": "v2.1.4", "source": { "type": "git", "url": "https://github.com/laravel/breeze.git", - "reference": "22c53b84b7fff91b01a318d71a10dfc251e92849" + "reference": "ef237081cc9b87c858e9de8e35b523f93ac74fd3" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/laravel/breeze/zipball/22c53b84b7fff91b01a318d71a10dfc251e92849", - "reference": "22c53b84b7fff91b01a318d71a10dfc251e92849", + "url": "https://api.github.com/repos/laravel/breeze/zipball/ef237081cc9b87c858e9de8e35b523f93ac74fd3", + "reference": "ef237081cc9b87c858e9de8e35b523f93ac74fd3", "shasum": "" }, "require": { - "illuminate/console": "^10.17", - "illuminate/filesystem": "^10.17", - "illuminate/support": "^10.17", - "illuminate/validation": "^10.17", - "php": "^8.1.0" + "illuminate/console": "^11.0", + "illuminate/filesystem": "^11.0", + "illuminate/support": "^11.0", + "illuminate/validation": "^11.0", + "php": "^8.2.0", + "symfony/console": "^7.0" }, "require-dev": { - "orchestra/testbench": "^8.0", + "orchestra/testbench": "^9.0", "phpstan/phpstan": "^1.10" }, "type": "library", "extra": { - "branch-alias": { - "dev-master": "1.x-dev" - }, "laravel": { "providers": [ "Laravel\\Breeze\\BreezeServiceProvider" @@ -1838,20 +1836,20 @@ "issues": "https://github.com/laravel/breeze/issues", "source": "https://github.com/laravel/breeze" }, - "time": "2024-03-04T14:35:21+00:00" + "time": "2024-08-12T22:06:50+00:00" }, { "name": "laravel/framework", - "version": "v10.48.20", + "version": "v11.21.0", "source": { "type": "git", "url": "https://github.com/laravel/framework.git", - "reference": "be2be342d4c74db6a8d2bd18469cd6d488ab9c98" + "reference": "9d9d36708d56665b12185493f684abce38ad2d30" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/laravel/framework/zipball/be2be342d4c74db6a8d2bd18469cd6d488ab9c98", - "reference": "be2be342d4c74db6a8d2bd18469cd6d488ab9c98", + "url": "https://api.github.com/repos/laravel/framework/zipball/9d9d36708d56665b12185493f684abce38ad2d30", + "reference": "9d9d36708d56665b12185493f684abce38ad2d30", "shasum": "" }, "require": { @@ -1867,44 +1865,44 @@ "ext-openssl": "*", "ext-session": "*", "ext-tokenizer": "*", - "fruitcake/php-cors": "^1.2", + "fruitcake/php-cors": "^1.3", + "guzzlehttp/guzzle": "^7.8", "guzzlehttp/uri-template": "^1.0", - "laravel/prompts": "^0.1.9", + "laravel/prompts": "^0.1.18", "laravel/serializable-closure": "^1.3", "league/commonmark": "^2.2.1", "league/flysystem": "^3.8.0", "monolog/monolog": "^3.0", - "nesbot/carbon": "^2.67", - "nunomaduro/termwind": "^1.13", - "php": "^8.1", + "nesbot/carbon": "^2.72.2|^3.0", + "nunomaduro/termwind": "^2.0", + "php": "^8.2", "psr/container": "^1.1.1|^2.0.1", "psr/log": "^1.0|^2.0|^3.0", "psr/simple-cache": "^1.0|^2.0|^3.0", "ramsey/uuid": "^4.7", - "symfony/console": "^6.2", - "symfony/error-handler": "^6.2", - "symfony/finder": "^6.2", - "symfony/http-foundation": "^6.4", - "symfony/http-kernel": "^6.2", - "symfony/mailer": "^6.2", - "symfony/mime": "^6.2", - "symfony/process": "^6.2", - "symfony/routing": "^6.2", - "symfony/uid": "^6.2", - "symfony/var-dumper": "^6.2", + "symfony/console": "^7.0", + "symfony/error-handler": "^7.0", + "symfony/finder": "^7.0", + "symfony/http-foundation": "^7.0", + "symfony/http-kernel": "^7.0", + "symfony/mailer": "^7.0", + "symfony/mime": "^7.0", + "symfony/polyfill-php83": "^1.28", + "symfony/process": "^7.0", + "symfony/routing": "^7.0", + "symfony/uid": "^7.0", + "symfony/var-dumper": "^7.0", "tijsverkoyen/css-to-inline-styles": "^2.2.5", "vlucas/phpdotenv": "^5.4.1", "voku/portable-ascii": "^2.0" }, "conflict": { - "carbonphp/carbon-doctrine-types": ">=3.0", - "doctrine/dbal": ">=4.0", "mockery/mockery": "1.6.8", - "phpunit/phpunit": ">=11.0.0", "tightenco/collect": "<5.5.33" }, "provide": { "psr/container-implementation": "1.1|2.0", + "psr/log-implementation": "1.0|2.0|3.0", "psr/simple-cache-implementation": "1.0|2.0|3.0" }, "replace": { @@ -1940,36 +1938,35 @@ "illuminate/testing": "self.version", "illuminate/translation": "self.version", "illuminate/validation": "self.version", - "illuminate/view": "self.version" + "illuminate/view": "self.version", + "spatie/once": "*" }, "require-dev": { "ably/ably-php": "^1.0", "aws/aws-sdk-php": "^3.235.5", - "doctrine/dbal": "^3.5.1", "ext-gmp": "*", - "fakerphp/faker": "^1.21", - "guzzlehttp/guzzle": "^7.5", + "fakerphp/faker": "^1.23", "league/flysystem-aws-s3-v3": "^3.0", "league/flysystem-ftp": "^3.0", "league/flysystem-path-prefixing": "^3.3", "league/flysystem-read-only": "^3.3", "league/flysystem-sftp-v3": "^3.0", - "mockery/mockery": "^1.5.1", + "mockery/mockery": "^1.6", "nyholm/psr7": "^1.2", - "orchestra/testbench-core": "^8.23.4", - "pda/pheanstalk": "^4.0", - "phpstan/phpstan": "^1.4.7", - "phpunit/phpunit": "^10.0.7", + "orchestra/testbench-core": "^9.1.5", + "pda/pheanstalk": "^5.0", + "phpstan/phpstan": "^1.11.5", + "phpunit/phpunit": "^10.5|^11.0", "predis/predis": "^2.0.2", - "symfony/cache": "^6.2", - "symfony/http-client": "^6.2.4", - "symfony/psr-http-message-bridge": "^2.0" + "resend/resend-php": "^0.10.0", + "symfony/cache": "^7.0", + "symfony/http-client": "^7.0", + "symfony/psr-http-message-bridge": "^7.0" }, "suggest": { "ably/ably-php": "Required to use the Ably broadcast driver (^1.0).", "aws/aws-sdk-php": "Required to use the SQS queue driver, DynamoDb failed job storage, and SES mail driver (^3.235.5).", - "brianium/paratest": "Required to run tests in parallel (^6.0).", - "doctrine/dbal": "Required to rename columns and drop SQLite columns (^3.5.1).", + "brianium/paratest": "Required to run tests in parallel (^7.0|^8.0).", "ext-apcu": "Required to use the APC cache driver.", "ext-fileinfo": "Required to use the Filesystem class.", "ext-ftp": "Required to use the Flysystem FTP driver.", @@ -1978,34 +1975,34 @@ "ext-pcntl": "Required to use all features of the queue worker and console signal trapping.", "ext-pdo": "Required to use all database features.", "ext-posix": "Required to use all features of the queue worker.", - "ext-redis": "Required to use the Redis cache and queue drivers (^4.0|^5.0).", + "ext-redis": "Required to use the Redis cache and queue drivers (^4.0|^5.0|^6.0).", "fakerphp/faker": "Required to use the eloquent factory builder (^1.9.1).", "filp/whoops": "Required for friendly error pages in development (^2.14.3).", - "guzzlehttp/guzzle": "Required to use the HTTP Client and the ping methods on schedules (^7.5).", "laravel/tinker": "Required to use the tinker console command (^2.0).", "league/flysystem-aws-s3-v3": "Required to use the Flysystem S3 driver (^3.0).", "league/flysystem-ftp": "Required to use the Flysystem FTP driver (^3.0).", "league/flysystem-path-prefixing": "Required to use the scoped driver (^3.3).", "league/flysystem-read-only": "Required to use read-only disks (^3.3)", "league/flysystem-sftp-v3": "Required to use the Flysystem SFTP driver (^3.0).", - "mockery/mockery": "Required to use mocking (^1.5.1).", + "mockery/mockery": "Required to use mocking (^1.6).", "nyholm/psr7": "Required to use PSR-7 bridging features (^1.2).", - "pda/pheanstalk": "Required to use the beanstalk queue driver (^4.0).", - "phpunit/phpunit": "Required to use assertions and run tests (^9.5.8|^10.0.7).", + "pda/pheanstalk": "Required to use the beanstalk queue driver (^5.0).", + "phpunit/phpunit": "Required to use assertions and run tests (^10.5|^11.0).", "predis/predis": "Required to use the predis connector (^2.0.2).", "psr/http-message": "Required to allow Storage::put to accept a StreamInterface (^1.0).", "pusher/pusher-php-server": "Required to use the Pusher broadcast driver (^6.0|^7.0).", - "symfony/cache": "Required to PSR-6 cache bridge (^6.2).", - "symfony/filesystem": "Required to enable support for relative symbolic links (^6.2).", - "symfony/http-client": "Required to enable support for the Symfony API mail transports (^6.2).", - "symfony/mailgun-mailer": "Required to enable support for the Mailgun mail transport (^6.2).", - "symfony/postmark-mailer": "Required to enable support for the Postmark mail transport (^6.2).", - "symfony/psr-http-message-bridge": "Required to use PSR-7 bridging features (^2.0)." + "resend/resend-php": "Required to enable support for the Resend mail transport (^0.10.0).", + "symfony/cache": "Required to PSR-6 cache bridge (^7.0).", + "symfony/filesystem": "Required to enable support for relative symbolic links (^7.0).", + "symfony/http-client": "Required to enable support for the Symfony API mail transports (^7.0).", + "symfony/mailgun-mailer": "Required to enable support for the Mailgun mail transport (^7.0).", + "symfony/postmark-mailer": "Required to enable support for the Postmark mail transport (^7.0).", + "symfony/psr-http-message-bridge": "Required to use PSR-7 bridging features (^7.0)." }, "type": "library", "extra": { "branch-alias": { - "dev-master": "10.x-dev" + "dev-master": "11.x-dev" } }, "autoload": { @@ -2045,7 +2042,7 @@ "issues": "https://github.com/laravel/framework/issues", "source": "https://github.com/laravel/framework" }, - "time": "2024-08-09T07:55:45+00:00" + "time": "2024-08-20T15:00:52+00:00" }, { "name": "laravel/prompts", @@ -2189,37 +2186,35 @@ }, { "name": "laravel/sanctum", - "version": "v3.3.3", + "version": "v4.0.2", "source": { "type": "git", "url": "https://github.com/laravel/sanctum.git", - "reference": "8c104366459739f3ada0e994bcd3e6fd681ce3d5" + "reference": "9cfc0ce80cabad5334efff73ec856339e8ec1ac1" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/laravel/sanctum/zipball/8c104366459739f3ada0e994bcd3e6fd681ce3d5", - "reference": "8c104366459739f3ada0e994bcd3e6fd681ce3d5", + "url": "https://api.github.com/repos/laravel/sanctum/zipball/9cfc0ce80cabad5334efff73ec856339e8ec1ac1", + "reference": "9cfc0ce80cabad5334efff73ec856339e8ec1ac1", "shasum": "" }, "require": { "ext-json": "*", - "illuminate/console": "^9.21|^10.0", - "illuminate/contracts": "^9.21|^10.0", - "illuminate/database": "^9.21|^10.0", - "illuminate/support": "^9.21|^10.0", - "php": "^8.0.2" + "illuminate/console": "^11.0", + "illuminate/contracts": "^11.0", + "illuminate/database": "^11.0", + "illuminate/support": "^11.0", + "php": "^8.2", + "symfony/console": "^7.0" }, "require-dev": { - "mockery/mockery": "^1.0", - "orchestra/testbench": "^7.28.2|^8.8.3", + "mockery/mockery": "^1.6", + "orchestra/testbench": "^9.0", "phpstan/phpstan": "^1.10", - "phpunit/phpunit": "^9.6" + "phpunit/phpunit": "^10.5" }, "type": "library", "extra": { - "branch-alias": { - "dev-master": "3.x-dev" - }, "laravel": { "providers": [ "Laravel\\Sanctum\\SanctumServiceProvider" @@ -2251,7 +2246,7 @@ "issues": "https://github.com/laravel/sanctum/issues", "source": "https://github.com/laravel/sanctum" }, - "time": "2023-12-19T18:44:48+00:00" + "time": "2024-04-10T19:39:58+00:00" }, { "name": "laravel/serializable-closure", @@ -3283,33 +3278,32 @@ }, { "name": "nunomaduro/termwind", - "version": "v1.15.1", + "version": "v2.0.1", "source": { "type": "git", "url": "https://github.com/nunomaduro/termwind.git", - "reference": "8ab0b32c8caa4a2e09700ea32925441385e4a5dc" + "reference": "58c4c58cf23df7f498daeb97092e34f5259feb6a" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/nunomaduro/termwind/zipball/8ab0b32c8caa4a2e09700ea32925441385e4a5dc", - "reference": "8ab0b32c8caa4a2e09700ea32925441385e4a5dc", + "url": "https://api.github.com/repos/nunomaduro/termwind/zipball/58c4c58cf23df7f498daeb97092e34f5259feb6a", + "reference": "58c4c58cf23df7f498daeb97092e34f5259feb6a", "shasum": "" }, "require": { "ext-mbstring": "*", - "php": "^8.0", - "symfony/console": "^5.3.0|^6.0.0" + "php": "^8.2", + "symfony/console": "^7.0.4" }, "require-dev": { - "ergebnis/phpstan-rules": "^1.0.", - "illuminate/console": "^8.0|^9.0", - "illuminate/support": "^8.0|^9.0", - "laravel/pint": "^1.0.0", - "pestphp/pest": "^1.21.0", - "pestphp/pest-plugin-mock": "^1.0", - "phpstan/phpstan": "^1.4.6", - "phpstan/phpstan-strict-rules": "^1.1.0", - "symfony/var-dumper": "^5.2.7|^6.0.0", + "ergebnis/phpstan-rules": "^2.2.0", + "illuminate/console": "^11.0.0", + "laravel/pint": "^1.14.0", + "mockery/mockery": "^1.6.7", + "pestphp/pest": "^2.34.1", + "phpstan/phpstan": "^1.10.59", + "phpstan/phpstan-strict-rules": "^1.5.2", + "symfony/var-dumper": "^7.0.4", "thecodingmachine/phpstan-strict-rules": "^1.0.0" }, "type": "library", @@ -3318,6 +3312,9 @@ "providers": [ "Termwind\\Laravel\\TermwindServiceProvider" ] + }, + "branch-alias": { + "dev-2.x": "2.x-dev" } }, "autoload": { @@ -3349,7 +3346,7 @@ ], "support": { "issues": "https://github.com/nunomaduro/termwind/issues", - "source": "https://github.com/nunomaduro/termwind/tree/v1.15.1" + "source": "https://github.com/nunomaduro/termwind/tree/v2.0.1" }, "funding": [ { @@ -3365,7 +3362,7 @@ "type": "github" } ], - "time": "2023-02-08T01:06:31+00:00" + "time": "2024-03-06T16:17:14+00:00" }, { "name": "paragonie/random_compat", @@ -5370,47 +5367,46 @@ }, { "name": "symfony/console", - "version": "v6.4.11", + "version": "v7.1.4", "source": { "type": "git", "url": "https://github.com/symfony/console.git", - "reference": "42686880adaacdad1835ee8fc2a9ec5b7bd63998" + "reference": "1eed7af6961d763e7832e874d7f9b21c3ea9c111" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/console/zipball/42686880adaacdad1835ee8fc2a9ec5b7bd63998", - "reference": "42686880adaacdad1835ee8fc2a9ec5b7bd63998", + "url": "https://api.github.com/repos/symfony/console/zipball/1eed7af6961d763e7832e874d7f9b21c3ea9c111", + "reference": "1eed7af6961d763e7832e874d7f9b21c3ea9c111", "shasum": "" }, "require": { - "php": ">=8.1", - "symfony/deprecation-contracts": "^2.5|^3", + "php": ">=8.2", "symfony/polyfill-mbstring": "~1.0", "symfony/service-contracts": "^2.5|^3", - "symfony/string": "^5.4|^6.0|^7.0" + "symfony/string": "^6.4|^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" + "symfony/dependency-injection": "<6.4", + "symfony/dotenv": "<6.4", + "symfony/event-dispatcher": "<6.4", + "symfony/lock": "<6.4", + "symfony/process": "<6.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/config": "^6.4|^7.0", + "symfony/dependency-injection": "^6.4|^7.0", + "symfony/event-dispatcher": "^6.4|^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" + "symfony/lock": "^6.4|^7.0", + "symfony/messenger": "^6.4|^7.0", + "symfony/process": "^6.4|^7.0", + "symfony/stopwatch": "^6.4|^7.0", + "symfony/var-dumper": "^6.4|^7.0" }, "type": "library", "autoload": { @@ -5444,7 +5440,7 @@ "terminal" ], "support": { - "source": "https://github.com/symfony/console/tree/v6.4.11" + "source": "https://github.com/symfony/console/tree/v7.1.4" }, "funding": [ { @@ -5460,7 +5456,7 @@ "type": "tidelift" } ], - "time": "2024-08-15T22:48:29+00:00" + "time": "2024-08-15T22:48:53+00:00" }, { "name": "symfony/css-selector", @@ -5596,22 +5592,22 @@ }, { "name": "symfony/error-handler", - "version": "v6.4.10", + "version": "v7.1.3", "source": { "type": "git", "url": "https://github.com/symfony/error-handler.git", - "reference": "231f1b2ee80f72daa1972f7340297d67439224f0" + "reference": "432bb369952795c61ca1def65e078c4a80dad13c" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/error-handler/zipball/231f1b2ee80f72daa1972f7340297d67439224f0", - "reference": "231f1b2ee80f72daa1972f7340297d67439224f0", + "url": "https://api.github.com/repos/symfony/error-handler/zipball/432bb369952795c61ca1def65e078c4a80dad13c", + "reference": "432bb369952795c61ca1def65e078c4a80dad13c", "shasum": "" }, "require": { - "php": ">=8.1", + "php": ">=8.2", "psr/log": "^1|^2|^3", - "symfony/var-dumper": "^5.4|^6.0|^7.0" + "symfony/var-dumper": "^6.4|^7.0" }, "conflict": { "symfony/deprecation-contracts": "<2.5", @@ -5620,7 +5616,7 @@ "require-dev": { "symfony/deprecation-contracts": "^2.5|^3", "symfony/http-kernel": "^6.4|^7.0", - "symfony/serializer": "^5.4|^6.0|^7.0" + "symfony/serializer": "^6.4|^7.0" }, "bin": [ "Resources/bin/patch-type-declarations" @@ -5651,7 +5647,7 @@ "description": "Provides tools to manage errors and ease debugging PHP code", "homepage": "https://symfony.com", "support": { - "source": "https://github.com/symfony/error-handler/tree/v6.4.10" + "source": "https://github.com/symfony/error-handler/tree/v7.1.3" }, "funding": [ { @@ -5667,7 +5663,7 @@ "type": "tidelift" } ], - "time": "2024-07-26T12:30:32+00:00" + "time": "2024-07-26T13:02:51+00:00" }, { "name": "symfony/event-dispatcher", @@ -5827,23 +5823,23 @@ }, { "name": "symfony/finder", - "version": "v6.4.11", + "version": "v7.1.4", "source": { "type": "git", "url": "https://github.com/symfony/finder.git", - "reference": "d7eb6daf8cd7e9ac4976e9576b32042ef7253453" + "reference": "d95bbf319f7d052082fb7af147e0f835a695e823" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/finder/zipball/d7eb6daf8cd7e9ac4976e9576b32042ef7253453", - "reference": "d7eb6daf8cd7e9ac4976e9576b32042ef7253453", + "url": "https://api.github.com/repos/symfony/finder/zipball/d95bbf319f7d052082fb7af147e0f835a695e823", + "reference": "d95bbf319f7d052082fb7af147e0f835a695e823", "shasum": "" }, "require": { - "php": ">=8.1" + "php": ">=8.2" }, "require-dev": { - "symfony/filesystem": "^6.0|^7.0" + "symfony/filesystem": "^6.4|^7.0" }, "type": "library", "autoload": { @@ -5871,7 +5867,7 @@ "description": "Finds files and directories via an intuitive fluent interface", "homepage": "https://symfony.com", "support": { - "source": "https://github.com/symfony/finder/tree/v6.4.11" + "source": "https://github.com/symfony/finder/tree/v7.1.4" }, "funding": [ { @@ -5887,40 +5883,40 @@ "type": "tidelift" } ], - "time": "2024-08-13T14:27:37+00:00" + "time": "2024-08-13T14:28:19+00:00" }, { "name": "symfony/http-foundation", - "version": "v6.4.10", + "version": "v7.1.3", "source": { "type": "git", "url": "https://github.com/symfony/http-foundation.git", - "reference": "117f1f20a7ade7bcea28b861fb79160a21a1e37b" + "reference": "f602d5c17d1fa02f8019ace2687d9d136b7f4a1a" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/http-foundation/zipball/117f1f20a7ade7bcea28b861fb79160a21a1e37b", - "reference": "117f1f20a7ade7bcea28b861fb79160a21a1e37b", + "url": "https://api.github.com/repos/symfony/http-foundation/zipball/f602d5c17d1fa02f8019ace2687d9d136b7f4a1a", + "reference": "f602d5c17d1fa02f8019ace2687d9d136b7f4a1a", "shasum": "" }, "require": { - "php": ">=8.1", - "symfony/deprecation-contracts": "^2.5|^3", + "php": ">=8.2", "symfony/polyfill-mbstring": "~1.1", "symfony/polyfill-php83": "^1.27" }, "conflict": { - "symfony/cache": "<6.3" + "doctrine/dbal": "<3.6", + "symfony/cache": "<6.4" }, "require-dev": { - "doctrine/dbal": "^2.13.1|^3|^4", + "doctrine/dbal": "^3.6|^4", "predis/predis": "^1.1|^2.0", - "symfony/cache": "^6.3|^7.0", - "symfony/dependency-injection": "^5.4|^6.0|^7.0", - "symfony/expression-language": "^5.4|^6.0|^7.0", - "symfony/http-kernel": "^5.4.12|^6.0.12|^6.1.4|^7.0", - "symfony/mime": "^5.4|^6.0|^7.0", - "symfony/rate-limiter": "^5.4|^6.0|^7.0" + "symfony/cache": "^6.4|^7.0", + "symfony/dependency-injection": "^6.4|^7.0", + "symfony/expression-language": "^6.4|^7.0", + "symfony/http-kernel": "^6.4|^7.0", + "symfony/mime": "^6.4|^7.0", + "symfony/rate-limiter": "^6.4|^7.0" }, "type": "library", "autoload": { @@ -5948,7 +5944,7 @@ "description": "Defines an object-oriented layer for the HTTP specification", "homepage": "https://symfony.com", "support": { - "source": "https://github.com/symfony/http-foundation/tree/v6.4.10" + "source": "https://github.com/symfony/http-foundation/tree/v7.1.3" }, "funding": [ { @@ -5964,77 +5960,77 @@ "type": "tidelift" } ], - "time": "2024-07-26T12:36:27+00:00" + "time": "2024-07-26T12:41:01+00:00" }, { "name": "symfony/http-kernel", - "version": "v6.4.11", + "version": "v7.1.4", "source": { "type": "git", "url": "https://github.com/symfony/http-kernel.git", - "reference": "1ba6b89d781cb47448155cc70dd2e0f1b0584c79" + "reference": "6efcbd1b3f444f631c386504fc83eeca25963747" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/http-kernel/zipball/1ba6b89d781cb47448155cc70dd2e0f1b0584c79", - "reference": "1ba6b89d781cb47448155cc70dd2e0f1b0584c79", + "url": "https://api.github.com/repos/symfony/http-kernel/zipball/6efcbd1b3f444f631c386504fc83eeca25963747", + "reference": "6efcbd1b3f444f631c386504fc83eeca25963747", "shasum": "" }, "require": { - "php": ">=8.1", + "php": ">=8.2", "psr/log": "^1|^2|^3", "symfony/deprecation-contracts": "^2.5|^3", "symfony/error-handler": "^6.4|^7.0", - "symfony/event-dispatcher": "^5.4|^6.0|^7.0", + "symfony/event-dispatcher": "^6.4|^7.0", "symfony/http-foundation": "^6.4|^7.0", "symfony/polyfill-ctype": "^1.8" }, "conflict": { - "symfony/browser-kit": "<5.4", - "symfony/cache": "<5.4", - "symfony/config": "<6.1", - "symfony/console": "<5.4", + "symfony/browser-kit": "<6.4", + "symfony/cache": "<6.4", + "symfony/config": "<6.4", + "symfony/console": "<6.4", "symfony/dependency-injection": "<6.4", - "symfony/doctrine-bridge": "<5.4", - "symfony/form": "<5.4", - "symfony/http-client": "<5.4", + "symfony/doctrine-bridge": "<6.4", + "symfony/form": "<6.4", + "symfony/http-client": "<6.4", "symfony/http-client-contracts": "<2.5", - "symfony/mailer": "<5.4", - "symfony/messenger": "<5.4", - "symfony/translation": "<5.4", + "symfony/mailer": "<6.4", + "symfony/messenger": "<6.4", + "symfony/translation": "<6.4", "symfony/translation-contracts": "<2.5", - "symfony/twig-bridge": "<5.4", + "symfony/twig-bridge": "<6.4", "symfony/validator": "<6.4", - "symfony/var-dumper": "<6.3", - "twig/twig": "<2.13" + "symfony/var-dumper": "<6.4", + "twig/twig": "<3.0.4" }, "provide": { "psr/log-implementation": "1.0|2.0|3.0" }, "require-dev": { "psr/cache": "^1.0|^2.0|^3.0", - "symfony/browser-kit": "^5.4|^6.0|^7.0", - "symfony/clock": "^6.2|^7.0", - "symfony/config": "^6.1|^7.0", - "symfony/console": "^5.4|^6.0|^7.0", - "symfony/css-selector": "^5.4|^6.0|^7.0", + "symfony/browser-kit": "^6.4|^7.0", + "symfony/clock": "^6.4|^7.0", + "symfony/config": "^6.4|^7.0", + "symfony/console": "^6.4|^7.0", + "symfony/css-selector": "^6.4|^7.0", "symfony/dependency-injection": "^6.4|^7.0", - "symfony/dom-crawler": "^5.4|^6.0|^7.0", - "symfony/expression-language": "^5.4|^6.0|^7.0", - "symfony/finder": "^5.4|^6.0|^7.0", + "symfony/dom-crawler": "^6.4|^7.0", + "symfony/expression-language": "^6.4|^7.0", + "symfony/finder": "^6.4|^7.0", "symfony/http-client-contracts": "^2.5|^3", - "symfony/process": "^5.4|^6.0|^7.0", - "symfony/property-access": "^5.4.5|^6.0.5|^7.0", - "symfony/routing": "^5.4|^6.0|^7.0", - "symfony/serializer": "^6.4.4|^7.0.4", - "symfony/stopwatch": "^5.4|^6.0|^7.0", - "symfony/translation": "^5.4|^6.0|^7.0", + "symfony/process": "^6.4|^7.0", + "symfony/property-access": "^7.1", + "symfony/routing": "^6.4|^7.0", + "symfony/serializer": "^7.1", + "symfony/stopwatch": "^6.4|^7.0", + "symfony/translation": "^6.4|^7.0", "symfony/translation-contracts": "^2.5|^3", - "symfony/uid": "^5.4|^6.0|^7.0", + "symfony/uid": "^6.4|^7.0", "symfony/validator": "^6.4|^7.0", - "symfony/var-dumper": "^5.4|^6.4|^7.0", - "symfony/var-exporter": "^6.2|^7.0", - "twig/twig": "^2.13|^3.0.4" + "symfony/var-dumper": "^6.4|^7.0", + "symfony/var-exporter": "^6.4|^7.0", + "twig/twig": "^3.0.4" }, "type": "library", "autoload": { @@ -6062,7 +6058,7 @@ "description": "Provides a structured process for converting a Request into a Response", "homepage": "https://symfony.com", "support": { - "source": "https://github.com/symfony/http-kernel/tree/v6.4.11" + "source": "https://github.com/symfony/http-kernel/tree/v7.1.4" }, "funding": [ { @@ -6078,43 +6074,43 @@ "type": "tidelift" } ], - "time": "2024-08-30T16:57:20+00:00" + "time": "2024-08-30T17:02:28+00:00" }, { "name": "symfony/mailer", - "version": "v6.4.9", + "version": "v7.1.2", "source": { "type": "git", "url": "https://github.com/symfony/mailer.git", - "reference": "e2d56f180f5b8c5e7c0fbea872bb1f529b6d6d45" + "reference": "8fcff0af9043c8f8a8e229437cea363e282f9aee" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/mailer/zipball/e2d56f180f5b8c5e7c0fbea872bb1f529b6d6d45", - "reference": "e2d56f180f5b8c5e7c0fbea872bb1f529b6d6d45", + "url": "https://api.github.com/repos/symfony/mailer/zipball/8fcff0af9043c8f8a8e229437cea363e282f9aee", + "reference": "8fcff0af9043c8f8a8e229437cea363e282f9aee", "shasum": "" }, "require": { "egulias/email-validator": "^2.1.10|^3|^4", - "php": ">=8.1", + "php": ">=8.2", "psr/event-dispatcher": "^1", "psr/log": "^1|^2|^3", - "symfony/event-dispatcher": "^5.4|^6.0|^7.0", - "symfony/mime": "^6.2|^7.0", + "symfony/event-dispatcher": "^6.4|^7.0", + "symfony/mime": "^6.4|^7.0", "symfony/service-contracts": "^2.5|^3" }, "conflict": { "symfony/http-client-contracts": "<2.5", - "symfony/http-kernel": "<5.4", - "symfony/messenger": "<6.2", - "symfony/mime": "<6.2", - "symfony/twig-bridge": "<6.2.1" + "symfony/http-kernel": "<6.4", + "symfony/messenger": "<6.4", + "symfony/mime": "<6.4", + "symfony/twig-bridge": "<6.4" }, "require-dev": { - "symfony/console": "^5.4|^6.0|^7.0", - "symfony/http-client": "^5.4|^6.0|^7.0", - "symfony/messenger": "^6.2|^7.0", - "symfony/twig-bridge": "^6.2|^7.0" + "symfony/console": "^6.4|^7.0", + "symfony/http-client": "^6.4|^7.0", + "symfony/messenger": "^6.4|^7.0", + "symfony/twig-bridge": "^6.4|^7.0" }, "type": "library", "autoload": { @@ -6142,7 +6138,7 @@ "description": "Helps sending emails", "homepage": "https://symfony.com", "support": { - "source": "https://github.com/symfony/mailer/tree/v6.4.9" + "source": "https://github.com/symfony/mailer/tree/v7.1.2" }, "funding": [ { @@ -6158,25 +6154,24 @@ "type": "tidelift" } ], - "time": "2024-06-28T07:59:05+00:00" + "time": "2024-06-28T08:00:31+00:00" }, { "name": "symfony/mime", - "version": "v6.4.11", + "version": "v7.1.4", "source": { "type": "git", "url": "https://github.com/symfony/mime.git", - "reference": "dba5d5f6073baf7a3576b580cc4a208b4ca00553" + "reference": "ccaa6c2503db867f472a587291e764d6a1e58758" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/mime/zipball/dba5d5f6073baf7a3576b580cc4a208b4ca00553", - "reference": "dba5d5f6073baf7a3576b580cc4a208b4ca00553", + "url": "https://api.github.com/repos/symfony/mime/zipball/ccaa6c2503db867f472a587291e764d6a1e58758", + "reference": "ccaa6c2503db867f472a587291e764d6a1e58758", "shasum": "" }, "require": { - "php": ">=8.1", - "symfony/deprecation-contracts": "^2.5|^3", + "php": ">=8.2", "symfony/polyfill-intl-idn": "^1.10", "symfony/polyfill-mbstring": "^1.0" }, @@ -6184,17 +6179,17 @@ "egulias/email-validator": "~3.0.0", "phpdocumentor/reflection-docblock": "<3.2.2", "phpdocumentor/type-resolver": "<1.4.0", - "symfony/mailer": "<5.4", + "symfony/mailer": "<6.4", "symfony/serializer": "<6.4.3|>7.0,<7.0.3" }, "require-dev": { "egulias/email-validator": "^2.1.10|^3.1|^4", "league/html-to-markdown": "^5.0", "phpdocumentor/reflection-docblock": "^3.0|^4.0|^5.0", - "symfony/dependency-injection": "^5.4|^6.0|^7.0", - "symfony/process": "^5.4|^6.4|^7.0", - "symfony/property-access": "^5.4|^6.0|^7.0", - "symfony/property-info": "^5.4|^6.0|^7.0", + "symfony/dependency-injection": "^6.4|^7.0", + "symfony/process": "^6.4|^7.0", + "symfony/property-access": "^6.4|^7.0", + "symfony/property-info": "^6.4|^7.0", "symfony/serializer": "^6.4.3|^7.0.3" }, "type": "library", @@ -6227,7 +6222,7 @@ "mime-type" ], "support": { - "source": "https://github.com/symfony/mime/tree/v6.4.11" + "source": "https://github.com/symfony/mime/tree/v7.1.4" }, "funding": [ { @@ -6243,7 +6238,7 @@ "type": "tidelift" } ], - "time": "2024-08-13T12:15:02+00:00" + "time": "2024-08-13T14:28:19+00:00" }, { "name": "symfony/options-resolver", @@ -7024,20 +7019,20 @@ }, { "name": "symfony/process", - "version": "v6.4.8", + "version": "v7.1.3", "source": { "type": "git", "url": "https://github.com/symfony/process.git", - "reference": "8d92dd79149f29e89ee0f480254db595f6a6a2c5" + "reference": "7f2f542c668ad6c313dc4a5e9c3321f733197eca" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/process/zipball/8d92dd79149f29e89ee0f480254db595f6a6a2c5", - "reference": "8d92dd79149f29e89ee0f480254db595f6a6a2c5", + "url": "https://api.github.com/repos/symfony/process/zipball/7f2f542c668ad6c313dc4a5e9c3321f733197eca", + "reference": "7f2f542c668ad6c313dc4a5e9c3321f733197eca", "shasum": "" }, "require": { - "php": ">=8.1" + "php": ">=8.2" }, "type": "library", "autoload": { @@ -7065,7 +7060,7 @@ "description": "Executes commands in sub-processes", "homepage": "https://symfony.com", "support": { - "source": "https://github.com/symfony/process/tree/v6.4.8" + "source": "https://github.com/symfony/process/tree/v7.1.3" }, "funding": [ { @@ -7081,40 +7076,38 @@ "type": "tidelift" } ], - "time": "2024-05-31T14:49:08+00:00" + "time": "2024-07-26T12:44:47+00:00" }, { "name": "symfony/routing", - "version": "v6.4.11", + "version": "v7.1.4", "source": { "type": "git", "url": "https://github.com/symfony/routing.git", - "reference": "8ee0c24c1bf61c263a26f1b9b6d19e83b1121f2a" + "reference": "1500aee0094a3ce1c92626ed8cf3c2037e86f5a7" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/routing/zipball/8ee0c24c1bf61c263a26f1b9b6d19e83b1121f2a", - "reference": "8ee0c24c1bf61c263a26f1b9b6d19e83b1121f2a", + "url": "https://api.github.com/repos/symfony/routing/zipball/1500aee0094a3ce1c92626ed8cf3c2037e86f5a7", + "reference": "1500aee0094a3ce1c92626ed8cf3c2037e86f5a7", "shasum": "" }, "require": { - "php": ">=8.1", + "php": ">=8.2", "symfony/deprecation-contracts": "^2.5|^3" }, "conflict": { - "doctrine/annotations": "<1.12", - "symfony/config": "<6.2", - "symfony/dependency-injection": "<5.4", - "symfony/yaml": "<5.4" + "symfony/config": "<6.4", + "symfony/dependency-injection": "<6.4", + "symfony/yaml": "<6.4" }, "require-dev": { - "doctrine/annotations": "^1.12|^2", "psr/log": "^1|^2|^3", - "symfony/config": "^6.2|^7.0", - "symfony/dependency-injection": "^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/yaml": "^5.4|^6.0|^7.0" + "symfony/config": "^6.4|^7.0", + "symfony/dependency-injection": "^6.4|^7.0", + "symfony/expression-language": "^6.4|^7.0", + "symfony/http-foundation": "^6.4|^7.0", + "symfony/yaml": "^6.4|^7.0" }, "type": "library", "autoload": { @@ -7148,7 +7141,7 @@ "url" ], "support": { - "source": "https://github.com/symfony/routing/tree/v6.4.11" + "source": "https://github.com/symfony/routing/tree/v7.1.4" }, "funding": [ { @@ -7164,7 +7157,7 @@ "type": "tidelift" } ], - "time": "2024-08-29T08:15:38+00:00" + "time": "2024-08-29T08:16:25+00:00" }, { "name": "symfony/service-contracts", @@ -7511,24 +7504,24 @@ }, { "name": "symfony/uid", - "version": "v6.4.11", + "version": "v7.1.4", "source": { "type": "git", "url": "https://github.com/symfony/uid.git", - "reference": "6a0394ad707de386547223948fac1e0f2805bc0b" + "reference": "82177535395109075cdb45a70533aa3d7a521cdf" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/uid/zipball/6a0394ad707de386547223948fac1e0f2805bc0b", - "reference": "6a0394ad707de386547223948fac1e0f2805bc0b", + "url": "https://api.github.com/repos/symfony/uid/zipball/82177535395109075cdb45a70533aa3d7a521cdf", + "reference": "82177535395109075cdb45a70533aa3d7a521cdf", "shasum": "" }, "require": { - "php": ">=8.1", + "php": ">=8.2", "symfony/polyfill-uuid": "^1.15" }, "require-dev": { - "symfony/console": "^5.4|^6.0|^7.0" + "symfony/console": "^6.4|^7.0" }, "type": "library", "autoload": { @@ -7565,7 +7558,7 @@ "uuid" ], "support": { - "source": "https://github.com/symfony/uid/tree/v6.4.11" + "source": "https://github.com/symfony/uid/tree/v7.1.4" }, "funding": [ { @@ -7581,38 +7574,36 @@ "type": "tidelift" } ], - "time": "2024-08-12T09:55:28+00:00" + "time": "2024-08-12T09:59:40+00:00" }, { "name": "symfony/var-dumper", - "version": "v6.4.11", + "version": "v7.1.4", "source": { "type": "git", "url": "https://github.com/symfony/var-dumper.git", - "reference": "ee14c8254a480913268b1e3b1cba8045ed122694" + "reference": "a5fa7481b199090964d6fd5dab6294d5a870c7aa" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/var-dumper/zipball/ee14c8254a480913268b1e3b1cba8045ed122694", - "reference": "ee14c8254a480913268b1e3b1cba8045ed122694", + "url": "https://api.github.com/repos/symfony/var-dumper/zipball/a5fa7481b199090964d6fd5dab6294d5a870c7aa", + "reference": "a5fa7481b199090964d6fd5dab6294d5a870c7aa", "shasum": "" }, "require": { - "php": ">=8.1", - "symfony/deprecation-contracts": "^2.5|^3", + "php": ">=8.2", "symfony/polyfill-mbstring": "~1.0" }, "conflict": { - "symfony/console": "<5.4" + "symfony/console": "<6.4" }, "require-dev": { "ext-iconv": "*", - "symfony/console": "^5.4|^6.0|^7.0", - "symfony/error-handler": "^6.3|^7.0", - "symfony/http-kernel": "^5.4|^6.0|^7.0", - "symfony/process": "^5.4|^6.0|^7.0", - "symfony/uid": "^5.4|^6.0|^7.0", - "twig/twig": "^2.13|^3.0.4" + "symfony/console": "^6.4|^7.0", + "symfony/http-kernel": "^6.4|^7.0", + "symfony/process": "^6.4|^7.0", + "symfony/uid": "^6.4|^7.0", + "twig/twig": "^3.0.4" }, "bin": [ "Resources/bin/var-dump-server" @@ -7650,7 +7641,7 @@ "dump" ], "support": { - "source": "https://github.com/symfony/var-dumper/tree/v6.4.11" + "source": "https://github.com/symfony/var-dumper/tree/v7.1.4" }, "funding": [ { @@ -7666,7 +7657,7 @@ "type": "tidelift" } ], - "time": "2024-08-30T16:03:21+00:00" + "time": "2024-08-30T16:12:47+00:00" }, { "name": "team-reflex/discord-php", @@ -8070,76 +8061,6 @@ } ], "packages-dev": [ - { - "name": "doctrine/instantiator", - "version": "2.0.0", - "source": { - "type": "git", - "url": "https://github.com/doctrine/instantiator.git", - "reference": "c6222283fa3f4ac679f8b9ced9a4e23f163e80d0" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/doctrine/instantiator/zipball/c6222283fa3f4ac679f8b9ced9a4e23f163e80d0", - "reference": "c6222283fa3f4ac679f8b9ced9a4e23f163e80d0", - "shasum": "" - }, - "require": { - "php": "^8.1" - }, - "require-dev": { - "doctrine/coding-standard": "^11", - "ext-pdo": "*", - "ext-phar": "*", - "phpbench/phpbench": "^1.2", - "phpstan/phpstan": "^1.9.4", - "phpstan/phpstan-phpunit": "^1.3", - "phpunit/phpunit": "^9.5.27", - "vimeo/psalm": "^5.4" - }, - "type": "library", - "autoload": { - "psr-4": { - "Doctrine\\Instantiator\\": "src/Doctrine/Instantiator/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Marco Pivetta", - "email": "ocramius@gmail.com", - "homepage": "https://ocramius.github.io/" - } - ], - "description": "A small, lightweight utility to instantiate objects in PHP without invoking their constructors", - "homepage": "https://www.doctrine-project.org/projects/instantiator.html", - "keywords": [ - "constructor", - "instantiate" - ], - "support": { - "issues": "https://github.com/doctrine/instantiator/issues", - "source": "https://github.com/doctrine/instantiator/tree/2.0.0" - }, - "funding": [ - { - "url": "https://www.doctrine-project.org/sponsorship.html", - "type": "custom" - }, - { - "url": "https://www.patreon.com/phpdoctrine", - "type": "patreon" - }, - { - "url": "https://tidelift.com/funding/github/packagist/doctrine%2Finstantiator", - "type": "tidelift" - } - ], - "time": "2022-12-30T00:23:10+00:00" - }, { "name": "fakerphp/faker", "version": "v1.23.1", @@ -8533,45 +8454,54 @@ }, { "name": "nunomaduro/collision", - "version": "v6.4.0", + "version": "v8.4.0", "source": { "type": "git", "url": "https://github.com/nunomaduro/collision.git", - "reference": "f05978827b9343cba381ca05b8c7deee346b6015" + "reference": "e7d1aa8ed753f63fa816932bbc89678238843b4a" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/nunomaduro/collision/zipball/f05978827b9343cba381ca05b8c7deee346b6015", - "reference": "f05978827b9343cba381ca05b8c7deee346b6015", + "url": "https://api.github.com/repos/nunomaduro/collision/zipball/e7d1aa8ed753f63fa816932bbc89678238843b4a", + "reference": "e7d1aa8ed753f63fa816932bbc89678238843b4a", "shasum": "" }, "require": { - "filp/whoops": "^2.14.5", - "php": "^8.0.0", - "symfony/console": "^6.0.2" + "filp/whoops": "^2.15.4", + "nunomaduro/termwind": "^2.0.1", + "php": "^8.2.0", + "symfony/console": "^7.1.3" + }, + "conflict": { + "laravel/framework": "<11.0.0 || >=12.0.0", + "phpunit/phpunit": "<10.5.1 || >=12.0.0" }, "require-dev": { - "brianium/paratest": "^6.4.1", - "laravel/framework": "^9.26.1", - "laravel/pint": "^1.1.1", - "nunomaduro/larastan": "^1.0.3", - "nunomaduro/mock-final-classes": "^1.1.0", - "orchestra/testbench": "^7.7", - "phpunit/phpunit": "^9.5.23", - "spatie/ignition": "^1.4.1" + "larastan/larastan": "^2.9.8", + "laravel/framework": "^11.19.0", + "laravel/pint": "^1.17.1", + "laravel/sail": "^1.31.0", + "laravel/sanctum": "^4.0.2", + "laravel/tinker": "^2.9.0", + "orchestra/testbench-core": "^9.2.3", + "pestphp/pest": "^2.35.0 || ^3.0.0", + "sebastian/environment": "^6.1.0 || ^7.0.0" }, "type": "library", "extra": { - "branch-alias": { - "dev-develop": "6.x-dev" - }, "laravel": { "providers": [ "NunoMaduro\\Collision\\Adapters\\Laravel\\CollisionServiceProvider" ] + }, + "branch-alias": { + "dev-8.x": "8.x-dev" } }, "autoload": { + "files": [ + "./src/Adapters/Phpunit/Autoload.php" + ], "psr-4": { "NunoMaduro\\Collision\\": "src/" } @@ -8617,7 +8547,7 @@ "type": "patreon" } ], - "time": "2023-01-03T12:54:54+00:00" + "time": "2024-08-03T15:32:23+00:00" }, { "name": "phar-io/manifest", @@ -8739,35 +8669,35 @@ }, { "name": "phpunit/php-code-coverage", - "version": "9.2.32", + "version": "11.0.6", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/php-code-coverage.git", - "reference": "85402a822d1ecf1db1096959413d35e1c37cf1a5" + "reference": "ebdffc9e09585dafa71b9bffcdb0a229d4704c45" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/85402a822d1ecf1db1096959413d35e1c37cf1a5", - "reference": "85402a822d1ecf1db1096959413d35e1c37cf1a5", + "url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/ebdffc9e09585dafa71b9bffcdb0a229d4704c45", + "reference": "ebdffc9e09585dafa71b9bffcdb0a229d4704c45", "shasum": "" }, "require": { "ext-dom": "*", "ext-libxml": "*", "ext-xmlwriter": "*", - "nikic/php-parser": "^4.19.1 || ^5.1.0", - "php": ">=7.3", - "phpunit/php-file-iterator": "^3.0.6", - "phpunit/php-text-template": "^2.0.4", - "sebastian/code-unit-reverse-lookup": "^2.0.3", - "sebastian/complexity": "^2.0.3", - "sebastian/environment": "^5.1.5", - "sebastian/lines-of-code": "^1.0.4", - "sebastian/version": "^3.0.2", + "nikic/php-parser": "^5.1.0", + "php": ">=8.2", + "phpunit/php-file-iterator": "^5.0.1", + "phpunit/php-text-template": "^4.0.1", + "sebastian/code-unit-reverse-lookup": "^4.0.1", + "sebastian/complexity": "^4.0.1", + "sebastian/environment": "^7.2.0", + "sebastian/lines-of-code": "^3.0.1", + "sebastian/version": "^5.0.1", "theseer/tokenizer": "^1.2.3" }, "require-dev": { - "phpunit/phpunit": "^9.6" + "phpunit/phpunit": "^11.0" }, "suggest": { "ext-pcov": "PHP extension that provides line coverage", @@ -8776,7 +8706,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-main": "9.2.x-dev" + "dev-main": "11.0.x-dev" } }, "autoload": { @@ -8805,7 +8735,7 @@ "support": { "issues": "https://github.com/sebastianbergmann/php-code-coverage/issues", "security": "https://github.com/sebastianbergmann/php-code-coverage/security/policy", - "source": "https://github.com/sebastianbergmann/php-code-coverage/tree/9.2.32" + "source": "https://github.com/sebastianbergmann/php-code-coverage/tree/11.0.6" }, "funding": [ { @@ -8813,32 +8743,32 @@ "type": "github" } ], - "time": "2024-08-22T04:23:01+00:00" + "time": "2024-08-22T04:37:56+00:00" }, { "name": "phpunit/php-file-iterator", - "version": "3.0.6", + "version": "5.1.0", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/php-file-iterator.git", - "reference": "cf1c2e7c203ac650e352f4cc675a7021e7d1b3cf" + "reference": "118cfaaa8bc5aef3287bf315b6060b1174754af6" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-file-iterator/zipball/cf1c2e7c203ac650e352f4cc675a7021e7d1b3cf", - "reference": "cf1c2e7c203ac650e352f4cc675a7021e7d1b3cf", + "url": "https://api.github.com/repos/sebastianbergmann/php-file-iterator/zipball/118cfaaa8bc5aef3287bf315b6060b1174754af6", + "reference": "118cfaaa8bc5aef3287bf315b6060b1174754af6", "shasum": "" }, "require": { - "php": ">=7.3" + "php": ">=8.2" }, "require-dev": { - "phpunit/phpunit": "^9.3" + "phpunit/phpunit": "^11.0" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "3.0-dev" + "dev-main": "5.0-dev" } }, "autoload": { @@ -8865,7 +8795,8 @@ ], "support": { "issues": "https://github.com/sebastianbergmann/php-file-iterator/issues", - "source": "https://github.com/sebastianbergmann/php-file-iterator/tree/3.0.6" + "security": "https://github.com/sebastianbergmann/php-file-iterator/security/policy", + "source": "https://github.com/sebastianbergmann/php-file-iterator/tree/5.1.0" }, "funding": [ { @@ -8873,28 +8804,28 @@ "type": "github" } ], - "time": "2021-12-02T12:48:52+00:00" + "time": "2024-08-27T05:02:59+00:00" }, { "name": "phpunit/php-invoker", - "version": "3.1.1", + "version": "5.0.1", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/php-invoker.git", - "reference": "5a10147d0aaf65b58940a0b72f71c9ac0423cc67" + "reference": "c1ca3814734c07492b3d4c5f794f4b0995333da2" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-invoker/zipball/5a10147d0aaf65b58940a0b72f71c9ac0423cc67", - "reference": "5a10147d0aaf65b58940a0b72f71c9ac0423cc67", + "url": "https://api.github.com/repos/sebastianbergmann/php-invoker/zipball/c1ca3814734c07492b3d4c5f794f4b0995333da2", + "reference": "c1ca3814734c07492b3d4c5f794f4b0995333da2", "shasum": "" }, "require": { - "php": ">=7.3" + "php": ">=8.2" }, "require-dev": { "ext-pcntl": "*", - "phpunit/phpunit": "^9.3" + "phpunit/phpunit": "^11.0" }, "suggest": { "ext-pcntl": "*" @@ -8902,7 +8833,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "3.1-dev" + "dev-main": "5.0-dev" } }, "autoload": { @@ -8928,7 +8859,8 @@ ], "support": { "issues": "https://github.com/sebastianbergmann/php-invoker/issues", - "source": "https://github.com/sebastianbergmann/php-invoker/tree/3.1.1" + "security": "https://github.com/sebastianbergmann/php-invoker/security/policy", + "source": "https://github.com/sebastianbergmann/php-invoker/tree/5.0.1" }, "funding": [ { @@ -8936,32 +8868,32 @@ "type": "github" } ], - "time": "2020-09-28T05:58:55+00:00" + "time": "2024-07-03T05:07:44+00:00" }, { "name": "phpunit/php-text-template", - "version": "2.0.4", + "version": "4.0.1", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/php-text-template.git", - "reference": "5da5f67fc95621df9ff4c4e5a84d6a8a2acf7c28" + "reference": "3e0404dc6b300e6bf56415467ebcb3fe4f33e964" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-text-template/zipball/5da5f67fc95621df9ff4c4e5a84d6a8a2acf7c28", - "reference": "5da5f67fc95621df9ff4c4e5a84d6a8a2acf7c28", + "url": "https://api.github.com/repos/sebastianbergmann/php-text-template/zipball/3e0404dc6b300e6bf56415467ebcb3fe4f33e964", + "reference": "3e0404dc6b300e6bf56415467ebcb3fe4f33e964", "shasum": "" }, "require": { - "php": ">=7.3" + "php": ">=8.2" }, "require-dev": { - "phpunit/phpunit": "^9.3" + "phpunit/phpunit": "^11.0" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "2.0-dev" + "dev-main": "4.0-dev" } }, "autoload": { @@ -8987,7 +8919,8 @@ ], "support": { "issues": "https://github.com/sebastianbergmann/php-text-template/issues", - "source": "https://github.com/sebastianbergmann/php-text-template/tree/2.0.4" + "security": "https://github.com/sebastianbergmann/php-text-template/security/policy", + "source": "https://github.com/sebastianbergmann/php-text-template/tree/4.0.1" }, "funding": [ { @@ -8995,32 +8928,32 @@ "type": "github" } ], - "time": "2020-10-26T05:33:50+00:00" + "time": "2024-07-03T05:08:43+00:00" }, { "name": "phpunit/php-timer", - "version": "5.0.3", + "version": "7.0.1", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/php-timer.git", - "reference": "5a63ce20ed1b5bf577850e2c4e87f4aa902afbd2" + "reference": "3b415def83fbcb41f991d9ebf16ae4ad8b7837b3" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-timer/zipball/5a63ce20ed1b5bf577850e2c4e87f4aa902afbd2", - "reference": "5a63ce20ed1b5bf577850e2c4e87f4aa902afbd2", + "url": "https://api.github.com/repos/sebastianbergmann/php-timer/zipball/3b415def83fbcb41f991d9ebf16ae4ad8b7837b3", + "reference": "3b415def83fbcb41f991d9ebf16ae4ad8b7837b3", "shasum": "" }, "require": { - "php": ">=7.3" + "php": ">=8.2" }, "require-dev": { - "phpunit/phpunit": "^9.3" + "phpunit/phpunit": "^11.0" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "5.0-dev" + "dev-main": "7.0-dev" } }, "autoload": { @@ -9046,7 +8979,8 @@ ], "support": { "issues": "https://github.com/sebastianbergmann/php-timer/issues", - "source": "https://github.com/sebastianbergmann/php-timer/tree/5.0.3" + "security": "https://github.com/sebastianbergmann/php-timer/security/policy", + "source": "https://github.com/sebastianbergmann/php-timer/tree/7.0.1" }, "funding": [ { @@ -9054,24 +8988,23 @@ "type": "github" } ], - "time": "2020-10-26T13:16:10+00:00" + "time": "2024-07-03T05:09:35+00:00" }, { "name": "phpunit/phpunit", - "version": "9.6.20", + "version": "11.3.1", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/phpunit.git", - "reference": "49d7820565836236411f5dc002d16dd689cde42f" + "reference": "fe179875ef0c14e90b75617002767eae0a742641" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/49d7820565836236411f5dc002d16dd689cde42f", - "reference": "49d7820565836236411f5dc002d16dd689cde42f", + "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/fe179875ef0c14e90b75617002767eae0a742641", + "reference": "fe179875ef0c14e90b75617002767eae0a742641", "shasum": "" }, "require": { - "doctrine/instantiator": "^1.5.0 || ^2", "ext-dom": "*", "ext-json": "*", "ext-libxml": "*", @@ -9081,27 +9014,25 @@ "myclabs/deep-copy": "^1.12.0", "phar-io/manifest": "^2.0.4", "phar-io/version": "^3.2.1", - "php": ">=7.3", - "phpunit/php-code-coverage": "^9.2.31", - "phpunit/php-file-iterator": "^3.0.6", - "phpunit/php-invoker": "^3.1.1", - "phpunit/php-text-template": "^2.0.4", - "phpunit/php-timer": "^5.0.3", - "sebastian/cli-parser": "^1.0.2", - "sebastian/code-unit": "^1.0.8", - "sebastian/comparator": "^4.0.8", - "sebastian/diff": "^4.0.6", - "sebastian/environment": "^5.1.5", - "sebastian/exporter": "^4.0.6", - "sebastian/global-state": "^5.0.7", - "sebastian/object-enumerator": "^4.0.4", - "sebastian/resource-operations": "^3.0.4", - "sebastian/type": "^3.2.1", - "sebastian/version": "^3.0.2" + "php": ">=8.2", + "phpunit/php-code-coverage": "^11.0.5", + "phpunit/php-file-iterator": "^5.0.1", + "phpunit/php-invoker": "^5.0.1", + "phpunit/php-text-template": "^4.0.1", + "phpunit/php-timer": "^7.0.1", + "sebastian/cli-parser": "^3.0.2", + "sebastian/code-unit": "^3.0.1", + "sebastian/comparator": "^6.0.2", + "sebastian/diff": "^6.0.2", + "sebastian/environment": "^7.2.0", + "sebastian/exporter": "^6.1.3", + "sebastian/global-state": "^7.0.2", + "sebastian/object-enumerator": "^6.0.1", + "sebastian/type": "^5.0.1", + "sebastian/version": "^5.0.1" }, "suggest": { - "ext-soap": "To be able to generate mocks based on WSDL files", - "ext-xdebug": "PHP extension that provides line coverage as well as branch and path coverage" + "ext-soap": "To be able to generate mocks based on WSDL files" }, "bin": [ "phpunit" @@ -9109,7 +9040,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "9.6-dev" + "dev-main": "11.3-dev" } }, "autoload": { @@ -9141,7 +9072,7 @@ "support": { "issues": "https://github.com/sebastianbergmann/phpunit/issues", "security": "https://github.com/sebastianbergmann/phpunit/security/policy", - "source": "https://github.com/sebastianbergmann/phpunit/tree/9.6.20" + "source": "https://github.com/sebastianbergmann/phpunit/tree/11.3.1" }, "funding": [ { @@ -9157,32 +9088,32 @@ "type": "tidelift" } ], - "time": "2024-07-10T11:45:39+00:00" + "time": "2024-08-13T06:14:23+00:00" }, { "name": "sebastian/cli-parser", - "version": "1.0.2", + "version": "3.0.2", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/cli-parser.git", - "reference": "2b56bea83a09de3ac06bb18b92f068e60cc6f50b" + "reference": "15c5dd40dc4f38794d383bb95465193f5e0ae180" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/cli-parser/zipball/2b56bea83a09de3ac06bb18b92f068e60cc6f50b", - "reference": "2b56bea83a09de3ac06bb18b92f068e60cc6f50b", + "url": "https://api.github.com/repos/sebastianbergmann/cli-parser/zipball/15c5dd40dc4f38794d383bb95465193f5e0ae180", + "reference": "15c5dd40dc4f38794d383bb95465193f5e0ae180", "shasum": "" }, "require": { - "php": ">=7.3" + "php": ">=8.2" }, "require-dev": { - "phpunit/phpunit": "^9.3" + "phpunit/phpunit": "^11.0" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "1.0-dev" + "dev-main": "3.0-dev" } }, "autoload": { @@ -9205,7 +9136,8 @@ "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.2" + "security": "https://github.com/sebastianbergmann/cli-parser/security/policy", + "source": "https://github.com/sebastianbergmann/cli-parser/tree/3.0.2" }, "funding": [ { @@ -9213,32 +9145,32 @@ "type": "github" } ], - "time": "2024-03-02T06:27:43+00:00" + "time": "2024-07-03T04:41:36+00:00" }, { "name": "sebastian/code-unit", - "version": "1.0.8", + "version": "3.0.1", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/code-unit.git", - "reference": "1fc9f64c0927627ef78ba436c9b17d967e68e120" + "reference": "6bb7d09d6623567178cf54126afa9c2310114268" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/code-unit/zipball/1fc9f64c0927627ef78ba436c9b17d967e68e120", - "reference": "1fc9f64c0927627ef78ba436c9b17d967e68e120", + "url": "https://api.github.com/repos/sebastianbergmann/code-unit/zipball/6bb7d09d6623567178cf54126afa9c2310114268", + "reference": "6bb7d09d6623567178cf54126afa9c2310114268", "shasum": "" }, "require": { - "php": ">=7.3" + "php": ">=8.2" }, "require-dev": { - "phpunit/phpunit": "^9.3" + "phpunit/phpunit": "^11.0" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "1.0-dev" + "dev-main": "3.0-dev" } }, "autoload": { @@ -9261,7 +9193,8 @@ "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" + "security": "https://github.com/sebastianbergmann/code-unit/security/policy", + "source": "https://github.com/sebastianbergmann/code-unit/tree/3.0.1" }, "funding": [ { @@ -9269,32 +9202,32 @@ "type": "github" } ], - "time": "2020-10-26T13:08:54+00:00" + "time": "2024-07-03T04:44:28+00:00" }, { "name": "sebastian/code-unit-reverse-lookup", - "version": "2.0.3", + "version": "4.0.1", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/code-unit-reverse-lookup.git", - "reference": "ac91f01ccec49fb77bdc6fd1e548bc70f7faa3e5" + "reference": "183a9b2632194febd219bb9246eee421dad8d45e" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/code-unit-reverse-lookup/zipball/ac91f01ccec49fb77bdc6fd1e548bc70f7faa3e5", - "reference": "ac91f01ccec49fb77bdc6fd1e548bc70f7faa3e5", + "url": "https://api.github.com/repos/sebastianbergmann/code-unit-reverse-lookup/zipball/183a9b2632194febd219bb9246eee421dad8d45e", + "reference": "183a9b2632194febd219bb9246eee421dad8d45e", "shasum": "" }, "require": { - "php": ">=7.3" + "php": ">=8.2" }, "require-dev": { - "phpunit/phpunit": "^9.3" + "phpunit/phpunit": "^11.0" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "2.0-dev" + "dev-main": "4.0-dev" } }, "autoload": { @@ -9316,7 +9249,8 @@ "homepage": "https://github.com/sebastianbergmann/code-unit-reverse-lookup/", "support": { "issues": "https://github.com/sebastianbergmann/code-unit-reverse-lookup/issues", - "source": "https://github.com/sebastianbergmann/code-unit-reverse-lookup/tree/2.0.3" + "security": "https://github.com/sebastianbergmann/code-unit-reverse-lookup/security/policy", + "source": "https://github.com/sebastianbergmann/code-unit-reverse-lookup/tree/4.0.1" }, "funding": [ { @@ -9324,34 +9258,36 @@ "type": "github" } ], - "time": "2020-09-28T05:30:19+00:00" + "time": "2024-07-03T04:45:54+00:00" }, { "name": "sebastian/comparator", - "version": "4.0.8", + "version": "6.0.2", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/comparator.git", - "reference": "fa0f136dd2334583309d32b62544682ee972b51a" + "reference": "450d8f237bd611c45b5acf0733ce43e6bb280f81" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/comparator/zipball/fa0f136dd2334583309d32b62544682ee972b51a", - "reference": "fa0f136dd2334583309d32b62544682ee972b51a", + "url": "https://api.github.com/repos/sebastianbergmann/comparator/zipball/450d8f237bd611c45b5acf0733ce43e6bb280f81", + "reference": "450d8f237bd611c45b5acf0733ce43e6bb280f81", "shasum": "" }, "require": { - "php": ">=7.3", - "sebastian/diff": "^4.0", - "sebastian/exporter": "^4.0" + "ext-dom": "*", + "ext-mbstring": "*", + "php": ">=8.2", + "sebastian/diff": "^6.0", + "sebastian/exporter": "^6.0" }, "require-dev": { - "phpunit/phpunit": "^9.3" + "phpunit/phpunit": "^11.0" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "4.0-dev" + "dev-main": "6.0-dev" } }, "autoload": { @@ -9390,7 +9326,8 @@ ], "support": { "issues": "https://github.com/sebastianbergmann/comparator/issues", - "source": "https://github.com/sebastianbergmann/comparator/tree/4.0.8" + "security": "https://github.com/sebastianbergmann/comparator/security/policy", + "source": "https://github.com/sebastianbergmann/comparator/tree/6.0.2" }, "funding": [ { @@ -9398,33 +9335,33 @@ "type": "github" } ], - "time": "2022-09-14T12:41:17+00:00" + "time": "2024-08-12T06:07:25+00:00" }, { "name": "sebastian/complexity", - "version": "2.0.3", + "version": "4.0.1", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/complexity.git", - "reference": "25f207c40d62b8b7aa32f5ab026c53561964053a" + "reference": "ee41d384ab1906c68852636b6de493846e13e5a0" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/complexity/zipball/25f207c40d62b8b7aa32f5ab026c53561964053a", - "reference": "25f207c40d62b8b7aa32f5ab026c53561964053a", + "url": "https://api.github.com/repos/sebastianbergmann/complexity/zipball/ee41d384ab1906c68852636b6de493846e13e5a0", + "reference": "ee41d384ab1906c68852636b6de493846e13e5a0", "shasum": "" }, "require": { - "nikic/php-parser": "^4.18 || ^5.0", - "php": ">=7.3" + "nikic/php-parser": "^5.0", + "php": ">=8.2" }, "require-dev": { - "phpunit/phpunit": "^9.3" + "phpunit/phpunit": "^11.0" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "2.0-dev" + "dev-main": "4.0-dev" } }, "autoload": { @@ -9447,7 +9384,8 @@ "homepage": "https://github.com/sebastianbergmann/complexity", "support": { "issues": "https://github.com/sebastianbergmann/complexity/issues", - "source": "https://github.com/sebastianbergmann/complexity/tree/2.0.3" + "security": "https://github.com/sebastianbergmann/complexity/security/policy", + "source": "https://github.com/sebastianbergmann/complexity/tree/4.0.1" }, "funding": [ { @@ -9455,33 +9393,33 @@ "type": "github" } ], - "time": "2023-12-22T06:19:30+00:00" + "time": "2024-07-03T04:49:50+00:00" }, { "name": "sebastian/diff", - "version": "4.0.6", + "version": "6.0.2", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/diff.git", - "reference": "ba01945089c3a293b01ba9badc29ad55b106b0bc" + "reference": "b4ccd857127db5d41a5b676f24b51371d76d8544" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/diff/zipball/ba01945089c3a293b01ba9badc29ad55b106b0bc", - "reference": "ba01945089c3a293b01ba9badc29ad55b106b0bc", + "url": "https://api.github.com/repos/sebastianbergmann/diff/zipball/b4ccd857127db5d41a5b676f24b51371d76d8544", + "reference": "b4ccd857127db5d41a5b676f24b51371d76d8544", "shasum": "" }, "require": { - "php": ">=7.3" + "php": ">=8.2" }, "require-dev": { - "phpunit/phpunit": "^9.3", + "phpunit/phpunit": "^11.0", "symfony/process": "^4.2 || ^5" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "4.0-dev" + "dev-main": "6.0-dev" } }, "autoload": { @@ -9513,7 +9451,8 @@ ], "support": { "issues": "https://github.com/sebastianbergmann/diff/issues", - "source": "https://github.com/sebastianbergmann/diff/tree/4.0.6" + "security": "https://github.com/sebastianbergmann/diff/security/policy", + "source": "https://github.com/sebastianbergmann/diff/tree/6.0.2" }, "funding": [ { @@ -9521,27 +9460,27 @@ "type": "github" } ], - "time": "2024-03-02T06:30:58+00:00" + "time": "2024-07-03T04:53:05+00:00" }, { "name": "sebastian/environment", - "version": "5.1.5", + "version": "7.2.0", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/environment.git", - "reference": "830c43a844f1f8d5b7a1f6d6076b784454d8b7ed" + "reference": "855f3ae0ab316bbafe1ba4e16e9f3c078d24a0c5" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/environment/zipball/830c43a844f1f8d5b7a1f6d6076b784454d8b7ed", - "reference": "830c43a844f1f8d5b7a1f6d6076b784454d8b7ed", + "url": "https://api.github.com/repos/sebastianbergmann/environment/zipball/855f3ae0ab316bbafe1ba4e16e9f3c078d24a0c5", + "reference": "855f3ae0ab316bbafe1ba4e16e9f3c078d24a0c5", "shasum": "" }, "require": { - "php": ">=7.3" + "php": ">=8.2" }, "require-dev": { - "phpunit/phpunit": "^9.3" + "phpunit/phpunit": "^11.0" }, "suggest": { "ext-posix": "*" @@ -9549,7 +9488,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "5.1-dev" + "dev-main": "7.2-dev" } }, "autoload": { @@ -9568,7 +9507,7 @@ } ], "description": "Provides functionality to handle HHVM/PHP environments", - "homepage": "http://www.github.com/sebastianbergmann/environment", + "homepage": "https://github.com/sebastianbergmann/environment", "keywords": [ "Xdebug", "environment", @@ -9576,7 +9515,8 @@ ], "support": { "issues": "https://github.com/sebastianbergmann/environment/issues", - "source": "https://github.com/sebastianbergmann/environment/tree/5.1.5" + "security": "https://github.com/sebastianbergmann/environment/security/policy", + "source": "https://github.com/sebastianbergmann/environment/tree/7.2.0" }, "funding": [ { @@ -9584,34 +9524,34 @@ "type": "github" } ], - "time": "2023-02-03T06:03:51+00:00" + "time": "2024-07-03T04:54:44+00:00" }, { "name": "sebastian/exporter", - "version": "4.0.6", + "version": "6.1.3", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/exporter.git", - "reference": "78c00df8f170e02473b682df15bfcdacc3d32d72" + "reference": "c414673eee9a8f9d51bbf8d61fc9e3ef1e85b20e" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/exporter/zipball/78c00df8f170e02473b682df15bfcdacc3d32d72", - "reference": "78c00df8f170e02473b682df15bfcdacc3d32d72", + "url": "https://api.github.com/repos/sebastianbergmann/exporter/zipball/c414673eee9a8f9d51bbf8d61fc9e3ef1e85b20e", + "reference": "c414673eee9a8f9d51bbf8d61fc9e3ef1e85b20e", "shasum": "" }, "require": { - "php": ">=7.3", - "sebastian/recursion-context": "^4.0" + "ext-mbstring": "*", + "php": ">=8.2", + "sebastian/recursion-context": "^6.0" }, "require-dev": { - "ext-mbstring": "*", - "phpunit/phpunit": "^9.3" + "phpunit/phpunit": "^11.2" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "4.0-dev" + "dev-main": "6.1-dev" } }, "autoload": { @@ -9653,7 +9593,8 @@ ], "support": { "issues": "https://github.com/sebastianbergmann/exporter/issues", - "source": "https://github.com/sebastianbergmann/exporter/tree/4.0.6" + "security": "https://github.com/sebastianbergmann/exporter/security/policy", + "source": "https://github.com/sebastianbergmann/exporter/tree/6.1.3" }, "funding": [ { @@ -9661,38 +9602,35 @@ "type": "github" } ], - "time": "2024-03-02T06:33:00+00:00" + "time": "2024-07-03T04:56:19+00:00" }, { "name": "sebastian/global-state", - "version": "5.0.7", + "version": "7.0.2", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/global-state.git", - "reference": "bca7df1f32ee6fe93b4d4a9abbf69e13a4ada2c9" + "reference": "3be331570a721f9a4b5917f4209773de17f747d7" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/global-state/zipball/bca7df1f32ee6fe93b4d4a9abbf69e13a4ada2c9", - "reference": "bca7df1f32ee6fe93b4d4a9abbf69e13a4ada2c9", + "url": "https://api.github.com/repos/sebastianbergmann/global-state/zipball/3be331570a721f9a4b5917f4209773de17f747d7", + "reference": "3be331570a721f9a4b5917f4209773de17f747d7", "shasum": "" }, "require": { - "php": ">=7.3", - "sebastian/object-reflector": "^2.0", - "sebastian/recursion-context": "^4.0" + "php": ">=8.2", + "sebastian/object-reflector": "^4.0", + "sebastian/recursion-context": "^6.0" }, "require-dev": { "ext-dom": "*", - "phpunit/phpunit": "^9.3" - }, - "suggest": { - "ext-uopz": "*" + "phpunit/phpunit": "^11.0" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "5.0-dev" + "dev-main": "7.0-dev" } }, "autoload": { @@ -9711,13 +9649,14 @@ } ], "description": "Snapshotting of global state", - "homepage": "http://www.github.com/sebastianbergmann/global-state", + "homepage": "https://www.github.com/sebastianbergmann/global-state", "keywords": [ "global state" ], "support": { "issues": "https://github.com/sebastianbergmann/global-state/issues", - "source": "https://github.com/sebastianbergmann/global-state/tree/5.0.7" + "security": "https://github.com/sebastianbergmann/global-state/security/policy", + "source": "https://github.com/sebastianbergmann/global-state/tree/7.0.2" }, "funding": [ { @@ -9725,33 +9664,33 @@ "type": "github" } ], - "time": "2024-03-02T06:35:11+00:00" + "time": "2024-07-03T04:57:36+00:00" }, { "name": "sebastian/lines-of-code", - "version": "1.0.4", + "version": "3.0.1", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/lines-of-code.git", - "reference": "e1e4a170560925c26d424b6a03aed157e7dcc5c5" + "reference": "d36ad0d782e5756913e42ad87cb2890f4ffe467a" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/lines-of-code/zipball/e1e4a170560925c26d424b6a03aed157e7dcc5c5", - "reference": "e1e4a170560925c26d424b6a03aed157e7dcc5c5", + "url": "https://api.github.com/repos/sebastianbergmann/lines-of-code/zipball/d36ad0d782e5756913e42ad87cb2890f4ffe467a", + "reference": "d36ad0d782e5756913e42ad87cb2890f4ffe467a", "shasum": "" }, "require": { - "nikic/php-parser": "^4.18 || ^5.0", - "php": ">=7.3" + "nikic/php-parser": "^5.0", + "php": ">=8.2" }, "require-dev": { - "phpunit/phpunit": "^9.3" + "phpunit/phpunit": "^11.0" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "1.0-dev" + "dev-main": "3.0-dev" } }, "autoload": { @@ -9774,7 +9713,8 @@ "homepage": "https://github.com/sebastianbergmann/lines-of-code", "support": { "issues": "https://github.com/sebastianbergmann/lines-of-code/issues", - "source": "https://github.com/sebastianbergmann/lines-of-code/tree/1.0.4" + "security": "https://github.com/sebastianbergmann/lines-of-code/security/policy", + "source": "https://github.com/sebastianbergmann/lines-of-code/tree/3.0.1" }, "funding": [ { @@ -9782,34 +9722,34 @@ "type": "github" } ], - "time": "2023-12-22T06:20:34+00:00" + "time": "2024-07-03T04:58:38+00:00" }, { "name": "sebastian/object-enumerator", - "version": "4.0.4", + "version": "6.0.1", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/object-enumerator.git", - "reference": "5c9eeac41b290a3712d88851518825ad78f45c71" + "reference": "f5b498e631a74204185071eb41f33f38d64608aa" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/object-enumerator/zipball/5c9eeac41b290a3712d88851518825ad78f45c71", - "reference": "5c9eeac41b290a3712d88851518825ad78f45c71", + "url": "https://api.github.com/repos/sebastianbergmann/object-enumerator/zipball/f5b498e631a74204185071eb41f33f38d64608aa", + "reference": "f5b498e631a74204185071eb41f33f38d64608aa", "shasum": "" }, "require": { - "php": ">=7.3", - "sebastian/object-reflector": "^2.0", - "sebastian/recursion-context": "^4.0" + "php": ">=8.2", + "sebastian/object-reflector": "^4.0", + "sebastian/recursion-context": "^6.0" }, "require-dev": { - "phpunit/phpunit": "^9.3" + "phpunit/phpunit": "^11.0" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "4.0-dev" + "dev-main": "6.0-dev" } }, "autoload": { @@ -9831,7 +9771,8 @@ "homepage": "https://github.com/sebastianbergmann/object-enumerator/", "support": { "issues": "https://github.com/sebastianbergmann/object-enumerator/issues", - "source": "https://github.com/sebastianbergmann/object-enumerator/tree/4.0.4" + "security": "https://github.com/sebastianbergmann/object-enumerator/security/policy", + "source": "https://github.com/sebastianbergmann/object-enumerator/tree/6.0.1" }, "funding": [ { @@ -9839,32 +9780,32 @@ "type": "github" } ], - "time": "2020-10-26T13:12:34+00:00" + "time": "2024-07-03T05:00:13+00:00" }, { "name": "sebastian/object-reflector", - "version": "2.0.4", + "version": "4.0.1", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/object-reflector.git", - "reference": "b4f479ebdbf63ac605d183ece17d8d7fe49c15c7" + "reference": "6e1a43b411b2ad34146dee7524cb13a068bb35f9" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/object-reflector/zipball/b4f479ebdbf63ac605d183ece17d8d7fe49c15c7", - "reference": "b4f479ebdbf63ac605d183ece17d8d7fe49c15c7", + "url": "https://api.github.com/repos/sebastianbergmann/object-reflector/zipball/6e1a43b411b2ad34146dee7524cb13a068bb35f9", + "reference": "6e1a43b411b2ad34146dee7524cb13a068bb35f9", "shasum": "" }, "require": { - "php": ">=7.3" + "php": ">=8.2" }, "require-dev": { - "phpunit/phpunit": "^9.3" + "phpunit/phpunit": "^11.0" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "2.0-dev" + "dev-main": "4.0-dev" } }, "autoload": { @@ -9886,7 +9827,8 @@ "homepage": "https://github.com/sebastianbergmann/object-reflector/", "support": { "issues": "https://github.com/sebastianbergmann/object-reflector/issues", - "source": "https://github.com/sebastianbergmann/object-reflector/tree/2.0.4" + "security": "https://github.com/sebastianbergmann/object-reflector/security/policy", + "source": "https://github.com/sebastianbergmann/object-reflector/tree/4.0.1" }, "funding": [ { @@ -9894,32 +9836,32 @@ "type": "github" } ], - "time": "2020-10-26T13:14:26+00:00" + "time": "2024-07-03T05:01:32+00:00" }, { "name": "sebastian/recursion-context", - "version": "4.0.5", + "version": "6.0.2", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/recursion-context.git", - "reference": "e75bd0f07204fec2a0af9b0f3cfe97d05f92efc1" + "reference": "694d156164372abbd149a4b85ccda2e4670c0e16" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/recursion-context/zipball/e75bd0f07204fec2a0af9b0f3cfe97d05f92efc1", - "reference": "e75bd0f07204fec2a0af9b0f3cfe97d05f92efc1", + "url": "https://api.github.com/repos/sebastianbergmann/recursion-context/zipball/694d156164372abbd149a4b85ccda2e4670c0e16", + "reference": "694d156164372abbd149a4b85ccda2e4670c0e16", "shasum": "" }, "require": { - "php": ">=7.3" + "php": ">=8.2" }, "require-dev": { - "phpunit/phpunit": "^9.3" + "phpunit/phpunit": "^11.0" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "4.0-dev" + "dev-main": "6.0-dev" } }, "autoload": { @@ -9949,7 +9891,8 @@ "homepage": "https://github.com/sebastianbergmann/recursion-context", "support": { "issues": "https://github.com/sebastianbergmann/recursion-context/issues", - "source": "https://github.com/sebastianbergmann/recursion-context/tree/4.0.5" + "security": "https://github.com/sebastianbergmann/recursion-context/security/policy", + "source": "https://github.com/sebastianbergmann/recursion-context/tree/6.0.2" }, "funding": [ { @@ -9957,86 +9900,32 @@ "type": "github" } ], - "time": "2023-02-03T06:07:39+00:00" - }, - { - "name": "sebastian/resource-operations", - "version": "3.0.4", - "source": { - "type": "git", - "url": "https://github.com/sebastianbergmann/resource-operations.git", - "reference": "05d5692a7993ecccd56a03e40cd7e5b09b1d404e" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/resource-operations/zipball/05d5692a7993ecccd56a03e40cd7e5b09b1d404e", - "reference": "05d5692a7993ecccd56a03e40cd7e5b09b1d404e", - "shasum": "" - }, - "require": { - "php": ">=7.3" - }, - "require-dev": { - "phpunit/phpunit": "^9.0" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-main": "3.0-dev" - } - }, - "autoload": { - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "authors": [ - { - "name": "Sebastian Bergmann", - "email": "sebastian@phpunit.de" - } - ], - "description": "Provides a list of PHP built-in functions that operate on resources", - "homepage": "https://www.github.com/sebastianbergmann/resource-operations", - "support": { - "source": "https://github.com/sebastianbergmann/resource-operations/tree/3.0.4" - }, - "funding": [ - { - "url": "https://github.com/sebastianbergmann", - "type": "github" - } - ], - "time": "2024-03-14T16:00:52+00:00" + "time": "2024-07-03T05:10:34+00:00" }, { "name": "sebastian/type", - "version": "3.2.1", + "version": "5.0.1", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/type.git", - "reference": "75e2c2a32f5e0b3aef905b9ed0b179b953b3d7c7" + "reference": "fb6a6566f9589e86661291d13eba708cce5eb4aa" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/type/zipball/75e2c2a32f5e0b3aef905b9ed0b179b953b3d7c7", - "reference": "75e2c2a32f5e0b3aef905b9ed0b179b953b3d7c7", + "url": "https://api.github.com/repos/sebastianbergmann/type/zipball/fb6a6566f9589e86661291d13eba708cce5eb4aa", + "reference": "fb6a6566f9589e86661291d13eba708cce5eb4aa", "shasum": "" }, "require": { - "php": ">=7.3" + "php": ">=8.2" }, "require-dev": { - "phpunit/phpunit": "^9.5" + "phpunit/phpunit": "^11.0" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "3.2-dev" + "dev-main": "5.0-dev" } }, "autoload": { @@ -10059,7 +9948,8 @@ "homepage": "https://github.com/sebastianbergmann/type", "support": { "issues": "https://github.com/sebastianbergmann/type/issues", - "source": "https://github.com/sebastianbergmann/type/tree/3.2.1" + "security": "https://github.com/sebastianbergmann/type/security/policy", + "source": "https://github.com/sebastianbergmann/type/tree/5.0.1" }, "funding": [ { @@ -10067,29 +9957,29 @@ "type": "github" } ], - "time": "2023-02-03T06:13:03+00:00" + "time": "2024-07-03T05:11:49+00:00" }, { "name": "sebastian/version", - "version": "3.0.2", + "version": "5.0.1", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/version.git", - "reference": "c6c1022351a901512170118436c764e473f6de8c" + "reference": "45c9debb7d039ce9b97de2f749c2cf5832a06ac4" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/version/zipball/c6c1022351a901512170118436c764e473f6de8c", - "reference": "c6c1022351a901512170118436c764e473f6de8c", + "url": "https://api.github.com/repos/sebastianbergmann/version/zipball/45c9debb7d039ce9b97de2f749c2cf5832a06ac4", + "reference": "45c9debb7d039ce9b97de2f749c2cf5832a06ac4", "shasum": "" }, "require": { - "php": ">=7.3" + "php": ">=8.2" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "3.0-dev" + "dev-main": "5.0-dev" } }, "autoload": { @@ -10112,7 +10002,8 @@ "homepage": "https://github.com/sebastianbergmann/version", "support": { "issues": "https://github.com/sebastianbergmann/version/issues", - "source": "https://github.com/sebastianbergmann/version/tree/3.0.2" + "security": "https://github.com/sebastianbergmann/version/security/policy", + "source": "https://github.com/sebastianbergmann/version/tree/5.0.1" }, "funding": [ { @@ -10120,7 +10011,7 @@ "type": "github" } ], - "time": "2020-09-28T06:39:44+00:00" + "time": "2024-07-03T05:13:08+00:00" }, { "name": "spatie/backtrace", diff --git a/phpunit.xml b/phpunit.xml index 2ac86a1..8f80490 100644 --- a/phpunit.xml +++ b/phpunit.xml @@ -1,31 +1,27 @@ - - - - ./tests/Unit - - - ./tests/Feature - - - - - ./app - - - - - - - - - - - - - + + + + ./tests/Unit + + + ./tests/Feature + + + + + + + + + + + + + + + + ./app + + diff --git a/tests/Unit/TwitchBot/IRCMessageTest.php b/tests/Unit/TwitchBot/IRCMessageTest.php index be0e242..c1b24f9 100644 --- a/tests/Unit/TwitchBot/IRCMessageTest.php +++ b/tests/Unit/TwitchBot/IRCMessageTest.php @@ -17,16 +17,16 @@ class IRCMessageTest extends TestCase { 'display-name' => 'Magnohato', 'emotes' => 'emotesv2_fb9cdf0d7fae484ab2e1d20e59a17ed2:0-11,19-30,38-49,58-69,80-91,100-111,122-133,139-150', 'first-msg' => '0', - 'flags' => '', + 'flags' => null, 'id' => '4b6fc216-18de-41d0-b92d-aeb28c690788', 'mod' => '0', - 'returning-chattea' => '0', + 'returning-chatter' => '0', 'room-id' => '30178469', 'subscriber' => '1', 'tmi-sent-ts' => '1712602818970', 'turbo' => '0', 'user-id' => '58325205', - 'user-type' => '', + 'user-type' => null, ], $msg->tags); $this->assertEquals('PRIVMSG', $msg->command); $this->assertEquals('magnohato', $msg->nick); -- 2.39.2 From b918c32c3f3a6cf82d2ad614e5fadcdc24e411a9 Mon Sep 17 00:00:00 2001 From: Daniel Karbach Date: Mon, 2 Sep 2024 13:46:04 +0200 Subject: [PATCH 03/16] upgrade larascord to v6 --- app/Http/Controllers/DiscordController.php | 161 ------------------ app/Models/User.php | 12 +- composer.json | 2 +- composer.lock | 21 ++- config/larascord.php | 4 + ...1158_add_remember_token_to_users_table.php | 28 +++ ...816_create_discord_access_tokens_table.php | 34 ++++ ..._remove_refresh_token_from_users_table.php | 28 +++ .../2023_06_11_062809_update_users_table.php | 42 +++++ routes/web.php | 10 +- 10 files changed, 159 insertions(+), 183 deletions(-) delete mode 100644 app/Http/Controllers/DiscordController.php create mode 100644 database/migrations/2023_05_25_121158_add_remember_token_to_users_table.php create mode 100644 database/migrations/2023_05_26_165816_create_discord_access_tokens_table.php create mode 100644 database/migrations/2023_05_27_055058_remove_refresh_token_from_users_table.php create mode 100644 database/migrations/2023_06_11_062809_update_users_table.php diff --git a/app/Http/Controllers/DiscordController.php b/app/Http/Controllers/DiscordController.php deleted file mode 100644 index 1625e32..0000000 --- a/app/Http/Controllers/DiscordController.php +++ /dev/null @@ -1,161 +0,0 @@ -missing('code')) { - if (env('APP_DEBUG')) { - return response()->json([ - 'larascord_message' => config('larascord.error_messages.missing_code', 'The authorization code is missing.'), - 'code' => 400 - ]); - } else { - return redirect('/')->with('error', config('larascord.error_messages.missing_code', 'The authorization code is missing.')); - } - } - - // Getting the access_token from the Discord API. - try { - $accessToken = $this->getDiscordAccessToken($request->get('code')); - } catch (\Exception $e) { - if (env('APP_DEBUG')) { - return response()->json([ - 'larascord_message' => config('larascord.error_messages.invalid_code', 'The authorization code is invalid.'), - 'message' => $e->getMessage(), - 'code' => $e->getCode() - ]); - } else { - return redirect('/')->with('error', config('larascord.error_messages.invalid_code', 'The authorization code is invalid.')); - } - } - - // Using the access_token to get the user's Discord ID. - try { - $user = $this->getDiscordUser($accessToken->access_token); - } catch (\Exception $e) { - if (env('APP_DEBUG')) { - return response()->json([ - 'larascord_message' => config('larascord.error_messages.authorization_failed', 'The authorization failed.'), - 'message' => $e->getMessage(), - 'code' => $e->getCode() - ]); - } else { - return redirect('/')->with('error', config('larascord.error_messages.authorization_failed', 'The authorization failed.')); - } - } - - // Making sure the current logged-in user's ID is matching the ID retrieved from the Discord API. - if (Auth::check() && (Auth::id() !== $user->id)) { - Auth::logout(); - return redirect('/')->with('error', config('larascord.error_messages.invalid_user', 'The user ID doesn\'t match the logged-in user.')); - } - - // Confirming the session in case the user was redirected from the password.confirm middleware. - if (Auth::check()) { - $request->session()->put('auth.password_confirmed_at', time()); - } - - // Trying to create or update the user in the database. - try { - $user = $this->createOrUpdateUser($user, $accessToken->refresh_token); - } catch (\Exception $e) { - if (env('APP_DEBUG')) { - return response()->json([ - 'larascord_message' => config('larascord.error_messages.database_error', 'There was an error while trying to create or update the user.'), - 'message' => $e->getMessage(), - 'code' => $e->getCode() - ]); - } else { - return redirect('/')->with('error', config('larascord.error_messages.database_error', 'There was an error while trying to create or update the user.')); - } - } - - // Authenticating the user if the user is not logged in. - if (!Auth::check()) { - Auth::login($user); - } - - // Redirecting the user to the intended page or to the home page. - return redirect()->intended(RouteServiceProvider::HOME); - } - - /** - * Handles the Discord OAuth2 callback. - * - * @param string $code - * @return object - * @throws \Illuminate\Http\Client\RequestException - */ - private function getDiscordAccessToken(string $code): object - { - $this->tokenData['code'] = $code; - - $response = Http::asForm()->post($this->tokenURL, $this->tokenData); - - $response->throw(); - - return json_decode($response->body()); - } - - /** - * Handles the Discord OAuth2 login. - * - * @param string $access_token - * @return object - * @throws \Illuminate\Http\Client\RequestException - */ - private function getDiscordUser(string $access_token): object - { - $response = Http::withToken($access_token)->get($this->apiURLBase); - - $response->throw(); - - return json_decode($response->body()); - } - - /** - * Handles the creation or update of the user. - * - * @param object $user - * @param string $refresh_token - * @return User - * @throws \Exception - */ - private function createOrUpdateUser(object $user, string $refresh_token): User - { - return User::updateOrCreate( - [ - 'id' => $user->id, - ], - [ - 'username' => $user->username, - 'discord_nickname' => isset($user->global_name) ? $user->global_name : NULL, - 'discriminator' => $user->discriminator, - 'email' => isset($user->email) ? $user->email : NULL, - 'avatar' => $user->avatar ?: NULL, - 'verified' => isset($user->verified) ? $user->verified : 0, - 'locale' => $user->locale, - 'mfa_enabled' => $user->mfa_enabled, - 'refresh_token' => $refresh_token - ] - ); - } - -} diff --git a/app/Models/User.php b/app/Models/User.php index db834b7..9360255 100644 --- a/app/Models/User.php +++ b/app/Models/User.php @@ -6,12 +6,13 @@ use Illuminate\Database\Eloquent\Builder; use Illuminate\Database\Eloquent\Factories\HasFactory; use Illuminate\Foundation\Auth\User as Authenticatable; use Illuminate\Notifications\Notifiable; +use Jakyeru\Larascord\Traits\InteractsWithDiscord; use Laravel\Sanctum\HasApiTokens; class User extends Authenticatable { - use HasApiTokens, HasFactory, Notifiable; + use HasApiTokens, HasFactory, InteractsWithDiscord, Notifiable; public function findResult(Round $round) { foreach ($round->results as $result) { @@ -195,14 +196,20 @@ class User extends Authenticatable 'id', 'username', 'discord_nickname', + 'global_name', 'discriminator', 'email', 'avatar', 'verified', + 'banner', + 'banner_color', + 'accent_color', 'locale', 'mfa_enabled', - 'refresh_token', + 'premium_type', + 'public_flags', 'role', + 'roles', ]; /** @@ -213,7 +220,6 @@ class User extends Authenticatable protected $hidden = [ 'email', 'mfa_enabled', - 'refresh_token', 'remember_token', ]; diff --git a/composer.json b/composer.json index 4a8569c..4b2522a 100644 --- a/composer.json +++ b/composer.json @@ -8,7 +8,7 @@ "php": "^8.1", "doctrine/dbal": "^3.3", "guzzlehttp/guzzle": "^7.2", - "jakyeru/larascord": "^3.0", + "jakyeru/larascord": "^6.0", "laravel/breeze": "^2.0", "laravel/framework": "^11.0", "laravel/reverb": "^1.2", diff --git a/composer.lock b/composer.lock index 9f1ff9e..f6b7cf0 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": "79d306d3125d944d59bac955ffb58da5", + "content-hash": "647b3c7cc8a622512318ec67392acbf8", "packages": [ { "name": "brick/math", @@ -1730,23 +1730,26 @@ }, { "name": "jakyeru/larascord", - "version": "v3.2.0", + "version": "v6.0.1", "source": { "type": "git", "url": "https://github.com/JakyeRU/Larascord.git", - "reference": "1ad8ac83e973b4b646ecdc78dcf94930131bada3" + "reference": "1673d0223a14114d7a1b09f6baa7d808b49f40ac" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/JakyeRU/Larascord/zipball/1ad8ac83e973b4b646ecdc78dcf94930131bada3", - "reference": "1ad8ac83e973b4b646ecdc78dcf94930131bada3", + "url": "https://api.github.com/repos/JakyeRU/Larascord/zipball/1673d0223a14114d7a1b09f6baa7d808b49f40ac", + "reference": "1673d0223a14114d7a1b09f6baa7d808b49f40ac", "shasum": "" }, "require": { - "guzzlehttp/guzzle": "^7.4" + "guzzlehttp/guzzle": "^7.5", + "laravel/breeze": "^v2.0", + "laravel/framework": "^11", + "php": "^8.2|^8.3" }, "require-dev": { - "orchestra/testbench": "^6.22" + "orchestra/testbench": "^9" }, "type": "library", "extra": { @@ -1774,9 +1777,9 @@ "description": "Larascord is a package that allows you to authenticate users in your Laravel application using Discord.", "support": { "issues": "https://github.com/JakyeRU/Larascord/issues", - "source": "https://github.com/JakyeRU/Larascord/tree/v3.2.0" + "source": "https://github.com/JakyeRU/Larascord/tree/v6.0.1" }, - "time": "2022-06-26T11:09:59+00:00" + "time": "2024-08-06T13:58:27+00:00" }, { "name": "laravel/breeze", diff --git a/config/larascord.php b/config/larascord.php index ee52e70..8696fc6 100644 --- a/config/larascord.php +++ b/config/larascord.php @@ -101,4 +101,8 @@ return [ 'database_error' => 'There was an error with the database. Please try again later.', ], + 'guilds' => [], + + 'guild_roles' => [], + ]; diff --git a/database/migrations/2023_05_25_121158_add_remember_token_to_users_table.php b/database/migrations/2023_05_25_121158_add_remember_token_to_users_table.php new file mode 100644 index 0000000..13f0499 --- /dev/null +++ b/database/migrations/2023_05_25_121158_add_remember_token_to_users_table.php @@ -0,0 +1,28 @@ +rememberToken()->after('refresh_token'); + }); + } + + /** + * Reverse the migrations. + */ + public function down(): void + { + Schema::table('users', function (Blueprint $table) { + $table->dropRememberToken(); + }); + } +}; diff --git a/database/migrations/2023_05_26_165816_create_discord_access_tokens_table.php b/database/migrations/2023_05_26_165816_create_discord_access_tokens_table.php new file mode 100644 index 0000000..2f8afec --- /dev/null +++ b/database/migrations/2023_05_26_165816_create_discord_access_tokens_table.php @@ -0,0 +1,34 @@ +id(); + $table->string('access_token'); + $table->string('refresh_token'); + $table->string('token_type'); + $table->integer('expires_in'); + $table->timestamp('expires_at'); + $table->string('scope'); + $table->foreignId('user_id')->constrained()->cascadeOnDelete(); + $table->timestamps(); + }); + } + + /** + * Reverse the migrations. + */ + public function down(): void + { + Schema::dropIfExists('discord_access_tokens'); + } +}; diff --git a/database/migrations/2023_05_27_055058_remove_refresh_token_from_users_table.php b/database/migrations/2023_05_27_055058_remove_refresh_token_from_users_table.php new file mode 100644 index 0000000..a6c14da --- /dev/null +++ b/database/migrations/2023_05_27_055058_remove_refresh_token_from_users_table.php @@ -0,0 +1,28 @@ +dropColumn('refresh_token'); + }); + } + + /** + * Reverse the migrations. + */ + public function down(): void + { + Schema::table('users', function (Blueprint $table) { + $table->string('refresh_token')->nullable(); + }); + } +}; diff --git a/database/migrations/2023_06_11_062809_update_users_table.php b/database/migrations/2023_06_11_062809_update_users_table.php new file mode 100644 index 0000000..9b903d9 --- /dev/null +++ b/database/migrations/2023_06_11_062809_update_users_table.php @@ -0,0 +1,42 @@ +string('global_name')->nullable()->after('username'); + $table->string('discriminator')->nullable()->change(); + $table->string('banner')->nullable()->after('verified'); + $table->string('banner_color')->nullable()->after('banner'); + $table->string('accent_color')->nullable()->after('banner_color'); + $table->string('premium_type')->nullable()->after('mfa_enabled'); + $table->string('public_flags')->nullable()->after('premium_type'); + $table->boolean('verified')->nullable()->change(); + }); + } + + /** + * Reverse the migrations. + */ + public function down(): void + { + Schema::table('users', function (Blueprint $table) { + $table->dropColumn('global_name'); + $table->string('discriminator')->change(); + $table->dropColumn('banner'); + $table->dropColumn('banner_color'); + $table->dropColumn('accent_color'); + $table->dropColumn('premium_type'); + $table->dropColumn('public_flags'); + $table->boolean('verified')->change(); + }); + } +}; diff --git a/routes/web.php b/routes/web.php index 53597af..2dcf298 100644 --- a/routes/web.php +++ b/routes/web.php @@ -1,11 +1,11 @@ where('path', '.*'); - -Route::group(['prefix' => config('larascord.prefix'), 'middleware' => ['web']], function() { - Route::get('/callback', [DiscordController::class, 'handle']) - ->name('larascord.login'); - - Route::redirect('/refresh-token', '/login') - ->name('larascord.refresh_token'); -}); -- 2.39.2 From f3900c99ffb66e55c939055966aec3176528cd85 Mon Sep 17 00:00:00 2001 From: Daniel Karbach Date: Mon, 2 Sep 2024 13:49:31 +0200 Subject: [PATCH 04/16] remove unused doctrine/dbal --- composer.json | 1 - composer.lock | 395 +------------------------------------------------- 2 files changed, 1 insertion(+), 395 deletions(-) diff --git a/composer.json b/composer.json index 4b2522a..3485031 100644 --- a/composer.json +++ b/composer.json @@ -6,7 +6,6 @@ "license": "MIT", "require": { "php": "^8.1", - "doctrine/dbal": "^3.3", "guzzlehttp/guzzle": "^7.2", "jakyeru/larascord": "^6.0", "laravel/breeze": "^2.0", diff --git a/composer.lock b/composer.lock index f6b7cf0..0b284da 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": "647b3c7cc8a622512318ec67392acbf8", + "content-hash": "ef0deb171a8e984bcc0ebabaef8c764f", "packages": [ { "name": "brick/math", @@ -441,350 +441,6 @@ }, "time": "2022-02-09T17:58:51+00:00" }, - { - "name": "doctrine/cache", - "version": "2.2.0", - "source": { - "type": "git", - "url": "https://github.com/doctrine/cache.git", - "reference": "1ca8f21980e770095a31456042471a57bc4c68fb" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/doctrine/cache/zipball/1ca8f21980e770095a31456042471a57bc4c68fb", - "reference": "1ca8f21980e770095a31456042471a57bc4c68fb", - "shasum": "" - }, - "require": { - "php": "~7.1 || ^8.0" - }, - "conflict": { - "doctrine/common": ">2.2,<2.4" - }, - "require-dev": { - "cache/integration-tests": "dev-master", - "doctrine/coding-standard": "^9", - "phpunit/phpunit": "^7.5 || ^8.5 || ^9.5", - "psr/cache": "^1.0 || ^2.0 || ^3.0", - "symfony/cache": "^4.4 || ^5.4 || ^6", - "symfony/var-exporter": "^4.4 || ^5.4 || ^6" - }, - "type": "library", - "autoload": { - "psr-4": { - "Doctrine\\Common\\Cache\\": "lib/Doctrine/Common/Cache" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Guilherme Blanco", - "email": "guilhermeblanco@gmail.com" - }, - { - "name": "Roman Borschel", - "email": "roman@code-factory.org" - }, - { - "name": "Benjamin Eberlei", - "email": "kontakt@beberlei.de" - }, - { - "name": "Jonathan Wage", - "email": "jonwage@gmail.com" - }, - { - "name": "Johannes Schmitt", - "email": "schmittjoh@gmail.com" - } - ], - "description": "PHP Doctrine Cache library is a popular cache implementation that supports many different drivers such as redis, memcache, apc, mongodb and others.", - "homepage": "https://www.doctrine-project.org/projects/cache.html", - "keywords": [ - "abstraction", - "apcu", - "cache", - "caching", - "couchdb", - "memcached", - "php", - "redis", - "xcache" - ], - "support": { - "issues": "https://github.com/doctrine/cache/issues", - "source": "https://github.com/doctrine/cache/tree/2.2.0" - }, - "funding": [ - { - "url": "https://www.doctrine-project.org/sponsorship.html", - "type": "custom" - }, - { - "url": "https://www.patreon.com/phpdoctrine", - "type": "patreon" - }, - { - "url": "https://tidelift.com/funding/github/packagist/doctrine%2Fcache", - "type": "tidelift" - } - ], - "time": "2022-05-20T20:07:39+00:00" - }, - { - "name": "doctrine/dbal", - "version": "3.9.0", - "source": { - "type": "git", - "url": "https://github.com/doctrine/dbal.git", - "reference": "d8f68ea6cc00912e5313237130b8c8decf4d28c6" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/doctrine/dbal/zipball/d8f68ea6cc00912e5313237130b8c8decf4d28c6", - "reference": "d8f68ea6cc00912e5313237130b8c8decf4d28c6", - "shasum": "" - }, - "require": { - "composer-runtime-api": "^2", - "doctrine/cache": "^1.11|^2.0", - "doctrine/deprecations": "^0.5.3|^1", - "doctrine/event-manager": "^1|^2", - "php": "^7.4 || ^8.0", - "psr/cache": "^1|^2|^3", - "psr/log": "^1|^2|^3" - }, - "require-dev": { - "doctrine/coding-standard": "12.0.0", - "fig/log-test": "^1", - "jetbrains/phpstorm-stubs": "2023.1", - "phpstan/phpstan": "1.11.7", - "phpstan/phpstan-strict-rules": "^1.6", - "phpunit/phpunit": "9.6.20", - "psalm/plugin-phpunit": "0.18.4", - "slevomat/coding-standard": "8.13.1", - "squizlabs/php_codesniffer": "3.10.2", - "symfony/cache": "^5.4|^6.0|^7.0", - "symfony/console": "^4.4|^5.4|^6.0|^7.0", - "vimeo/psalm": "4.30.0" - }, - "suggest": { - "symfony/console": "For helpful console commands such as SQL execution and import of files." - }, - "bin": [ - "bin/doctrine-dbal" - ], - "type": "library", - "autoload": { - "psr-4": { - "Doctrine\\DBAL\\": "src" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Guilherme Blanco", - "email": "guilhermeblanco@gmail.com" - }, - { - "name": "Roman Borschel", - "email": "roman@code-factory.org" - }, - { - "name": "Benjamin Eberlei", - "email": "kontakt@beberlei.de" - }, - { - "name": "Jonathan Wage", - "email": "jonwage@gmail.com" - } - ], - "description": "Powerful PHP database abstraction layer (DBAL) with many features for database schema introspection and management.", - "homepage": "https://www.doctrine-project.org/projects/dbal.html", - "keywords": [ - "abstraction", - "database", - "db2", - "dbal", - "mariadb", - "mssql", - "mysql", - "oci8", - "oracle", - "pdo", - "pgsql", - "postgresql", - "queryobject", - "sasql", - "sql", - "sqlite", - "sqlserver", - "sqlsrv" - ], - "support": { - "issues": "https://github.com/doctrine/dbal/issues", - "source": "https://github.com/doctrine/dbal/tree/3.9.0" - }, - "funding": [ - { - "url": "https://www.doctrine-project.org/sponsorship.html", - "type": "custom" - }, - { - "url": "https://www.patreon.com/phpdoctrine", - "type": "patreon" - }, - { - "url": "https://tidelift.com/funding/github/packagist/doctrine%2Fdbal", - "type": "tidelift" - } - ], - "time": "2024-08-15T07:34:42+00:00" - }, - { - "name": "doctrine/deprecations", - "version": "1.1.3", - "source": { - "type": "git", - "url": "https://github.com/doctrine/deprecations.git", - "reference": "dfbaa3c2d2e9a9df1118213f3b8b0c597bb99fab" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/doctrine/deprecations/zipball/dfbaa3c2d2e9a9df1118213f3b8b0c597bb99fab", - "reference": "dfbaa3c2d2e9a9df1118213f3b8b0c597bb99fab", - "shasum": "" - }, - "require": { - "php": "^7.1 || ^8.0" - }, - "require-dev": { - "doctrine/coding-standard": "^9", - "phpstan/phpstan": "1.4.10 || 1.10.15", - "phpstan/phpstan-phpunit": "^1.0", - "phpunit/phpunit": "^7.5 || ^8.5 || ^9.5", - "psalm/plugin-phpunit": "0.18.4", - "psr/log": "^1 || ^2 || ^3", - "vimeo/psalm": "4.30.0 || 5.12.0" - }, - "suggest": { - "psr/log": "Allows logging deprecations via PSR-3 logger implementation" - }, - "type": "library", - "autoload": { - "psr-4": { - "Doctrine\\Deprecations\\": "lib/Doctrine/Deprecations" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "description": "A small layer on top of trigger_error(E_USER_DEPRECATED) or PSR-3 logging with options to disable all deprecations or selectively for packages.", - "homepage": "https://www.doctrine-project.org/", - "support": { - "issues": "https://github.com/doctrine/deprecations/issues", - "source": "https://github.com/doctrine/deprecations/tree/1.1.3" - }, - "time": "2024-01-30T19:34:25+00:00" - }, - { - "name": "doctrine/event-manager", - "version": "2.0.1", - "source": { - "type": "git", - "url": "https://github.com/doctrine/event-manager.git", - "reference": "b680156fa328f1dfd874fd48c7026c41570b9c6e" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/doctrine/event-manager/zipball/b680156fa328f1dfd874fd48c7026c41570b9c6e", - "reference": "b680156fa328f1dfd874fd48c7026c41570b9c6e", - "shasum": "" - }, - "require": { - "php": "^8.1" - }, - "conflict": { - "doctrine/common": "<2.9" - }, - "require-dev": { - "doctrine/coding-standard": "^12", - "phpstan/phpstan": "^1.8.8", - "phpunit/phpunit": "^10.5", - "vimeo/psalm": "^5.24" - }, - "type": "library", - "autoload": { - "psr-4": { - "Doctrine\\Common\\": "src" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Guilherme Blanco", - "email": "guilhermeblanco@gmail.com" - }, - { - "name": "Roman Borschel", - "email": "roman@code-factory.org" - }, - { - "name": "Benjamin Eberlei", - "email": "kontakt@beberlei.de" - }, - { - "name": "Jonathan Wage", - "email": "jonwage@gmail.com" - }, - { - "name": "Johannes Schmitt", - "email": "schmittjoh@gmail.com" - }, - { - "name": "Marco Pivetta", - "email": "ocramius@gmail.com" - } - ], - "description": "The Doctrine Event Manager is a simple PHP event system that was built to be used with the various Doctrine projects.", - "homepage": "https://www.doctrine-project.org/projects/event-manager.html", - "keywords": [ - "event", - "event dispatcher", - "event manager", - "event system", - "events" - ], - "support": { - "issues": "https://github.com/doctrine/event-manager/issues", - "source": "https://github.com/doctrine/event-manager/tree/2.0.1" - }, - "funding": [ - { - "url": "https://www.doctrine-project.org/sponsorship.html", - "type": "custom" - }, - { - "url": "https://www.patreon.com/phpdoctrine", - "type": "patreon" - }, - { - "url": "https://tidelift.com/funding/github/packagist/doctrine%2Fevent-manager", - "type": "tidelift" - } - ], - "time": "2024-05-22T20:47:39+00:00" - }, { "name": "doctrine/inflector", "version": "2.0.10", @@ -3629,55 +3285,6 @@ ], "time": "2024-07-20T21:41:07+00:00" }, - { - "name": "psr/cache", - "version": "3.0.0", - "source": { - "type": "git", - "url": "https://github.com/php-fig/cache.git", - "reference": "aa5030cfa5405eccfdcb1083ce040c2cb8d253bf" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/php-fig/cache/zipball/aa5030cfa5405eccfdcb1083ce040c2cb8d253bf", - "reference": "aa5030cfa5405eccfdcb1083ce040c2cb8d253bf", - "shasum": "" - }, - "require": { - "php": ">=8.0.0" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.0.x-dev" - } - }, - "autoload": { - "psr-4": { - "Psr\\Cache\\": "src/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "PHP-FIG", - "homepage": "https://www.php-fig.org/" - } - ], - "description": "Common interface for caching libraries", - "keywords": [ - "cache", - "psr", - "psr-6" - ], - "support": { - "source": "https://github.com/php-fig/cache/tree/3.0.0" - }, - "time": "2021-02-03T23:26:27+00:00" - }, { "name": "psr/clock", "version": "1.0.0", -- 2.39.2 From 1e5f8d0595fc069ac0ff2dde8808fef00731f159 Mon Sep 17 00:00:00 2001 From: Daniel Karbach Date: Mon, 2 Sep 2024 14:03:23 +0200 Subject: [PATCH 05/16] default props -> default arguments --- resources/js/components/chat-bot-logs/Item.js | 6 +--- resources/js/components/chat-bot-logs/List.js | 6 +--- resources/js/components/common/AspectBox.js | 7 +--- resources/js/components/common/Icon.js | 15 +++----- resources/js/components/common/LargeCheck.js | 21 ++++------- resources/js/components/common/Slider.js | 6 +--- .../js/components/common/ToggleSwitch.js | 35 ++++++------------- resources/js/components/protocol/Item.js | 6 +--- resources/js/components/protocol/List.js | 6 +--- .../js/components/rounds/SeedCodeInput.js | 21 ++++------- resources/js/components/tracker/Dungeons.js | 6 +--- 11 files changed, 33 insertions(+), 102 deletions(-) diff --git a/resources/js/components/chat-bot-logs/Item.js b/resources/js/components/chat-bot-logs/Item.js index f50d078..4c55c59 100644 --- a/resources/js/components/chat-bot-logs/Item.js +++ b/resources/js/components/chat-bot-logs/Item.js @@ -39,7 +39,7 @@ const getEntryInfo = (entry, t) => { return getEntryDate(entry); }; -const Item = ({ entry }) => { +const Item = ({ entry = {} }) => { const { t } = useTranslation(); return @@ -72,8 +72,4 @@ Item.propTypes = { }), }; -Item.defaultProps = { - entry: {}, -}; - export default Item; diff --git a/resources/js/components/chat-bot-logs/List.js b/resources/js/components/chat-bot-logs/List.js index 9838b8e..0411299 100644 --- a/resources/js/components/chat-bot-logs/List.js +++ b/resources/js/components/chat-bot-logs/List.js @@ -4,7 +4,7 @@ import { ListGroup } from 'react-bootstrap'; import Item from './Item'; -const List = ({ log }) => +const List = ({ log = [] }) => {log ? log.map(entry => @@ -16,8 +16,4 @@ List.propTypes = { })), }; -List.defaultProps = { - log: [], -}; - export default List; diff --git a/resources/js/components/common/AspectBox.js b/resources/js/components/common/AspectBox.js index 52709c1..ead009d 100644 --- a/resources/js/components/common/AspectBox.js +++ b/resources/js/components/common/AspectBox.js @@ -1,7 +1,7 @@ import PropTypes from 'prop-types'; import React from 'react'; -const AspectBox = ({ children, ratio }) => +const AspectBox = ({ children = null, ratio = 1 }) =>
{children} @@ -13,9 +13,4 @@ AspectBox.propTypes = { ratio: PropTypes.number, }; -AspectBox.defaultProps = { - children: null, - ratio: 1, -}; - export default AspectBox; diff --git a/resources/js/components/common/Icon.js b/resources/js/components/common/Icon.js index f3caeb3..56d5862 100644 --- a/resources/js/components/common/Icon.js +++ b/resources/js/components/common/Icon.js @@ -12,11 +12,11 @@ library.add(fab); library.add(fas); const Icon = ({ - alt, - className, + alt = null, + className = '', name, - size, - title, + size = null, + title = null, }) => { const preset = ({ alt, className, name, size, title}) => { let clsn = className ? `${className} custom-check` : 'custom-check'; if (value) { @@ -42,13 +42,4 @@ LargeCheck.propTypes = { value: PropTypes.bool, }; -LargeCheck.defaultProps = { - className: '', - id: '', - name: '', - onBlur: null, - onChange: null, - value: false, -}; - export default LargeCheck; diff --git a/resources/js/components/common/Slider.js b/resources/js/components/common/Slider.js index 634c15c..587fc7f 100644 --- a/resources/js/components/common/Slider.js +++ b/resources/js/components/common/Slider.js @@ -1,7 +1,7 @@ import PropTypes from 'prop-types'; import React from 'react'; -const Slider = ({ children, duration, vertical }) => { +const Slider = ({ children = null, duration = 2500, vertical = false }) => { const [index, setIndex] = React.useState(0); React.useEffect(() => { @@ -28,10 +28,6 @@ Slider.propTypes = { vertical: PropTypes.bool, }; -Slider.defaultProps = { - duration: 2500, -}; - const Slide = ({ children }) => { return
{children} diff --git a/resources/js/components/common/ToggleSwitch.js b/resources/js/components/common/ToggleSwitch.js index db07619..98d3d06 100644 --- a/resources/js/components/common/ToggleSwitch.js +++ b/resources/js/components/common/ToggleSwitch.js @@ -4,16 +4,16 @@ import React from 'react'; import Icon from './Icon'; const ToggleSwitch = ({ - isInvalid, - isValid, - name, - offLabel, - onBlur, - onChange, - onLabel, - readonly, - title, - value, + isInvalid = false, + isValid = false, + name = '', + offLabel = '', + onBlur = null, + onChange = null, + onLabel = null, + readonly = false, + title = null, + value = false, }) => { const toggle = () => { if (readonly) return; @@ -61,7 +61,6 @@ const ToggleSwitch = ({ }; ToggleSwitch.propTypes = { - id: PropTypes.string, isInvalid: PropTypes.bool, isValid: PropTypes.bool, name: PropTypes.string, @@ -74,18 +73,4 @@ ToggleSwitch.propTypes = { value: PropTypes.bool, }; -ToggleSwitch.defaultProps = { - id: '', - isInvalid: false, - isValid: false, - name: '', - offLabel: '', - onBlur: null, - onChange: null, - onLabel: '', - readonly: false, - title: null, - value: false, -}; - export default ToggleSwitch; diff --git a/resources/js/components/protocol/Item.js b/resources/js/components/protocol/Item.js index 7dba2a3..7c3da40 100644 --- a/resources/js/components/protocol/Item.js +++ b/resources/js/components/protocol/Item.js @@ -115,7 +115,7 @@ const getEntryIcon = entry => { } }; -const Item = ({ entry }) => +const Item = ({ entry = {} }) =>
{getEntryIcon(entry)} @@ -139,8 +139,4 @@ Item.propTypes = { }), }; -Item.defaultProps = { - entry: {}, -}; - export default withTranslation()(Item); diff --git a/resources/js/components/protocol/List.js b/resources/js/components/protocol/List.js index 55e0ecb..9179ad5 100644 --- a/resources/js/components/protocol/List.js +++ b/resources/js/components/protocol/List.js @@ -4,7 +4,7 @@ import { ListGroup } from 'react-bootstrap'; import Item from './Item'; -const List = ({ protocol }) => +const List = ({ protocol = [] }) => {protocol ? protocol.map(entry => @@ -16,8 +16,4 @@ List.propTypes = { })), }; -List.defaultProps = { - protocol: [], -}; - export default List; diff --git a/resources/js/components/rounds/SeedCodeInput.js b/resources/js/components/rounds/SeedCodeInput.js index 2431ca3..958c927 100644 --- a/resources/js/components/rounds/SeedCodeInput.js +++ b/resources/js/components/rounds/SeedCodeInput.js @@ -76,12 +76,12 @@ const SMR_CODES = [ ]; const SeedCodeInput = ({ - className, - game, - name, - onBlur, - onChange, - value, + className = '', + game = '', + name = '', + onBlur = null, + onChange = null, + value = [], }) => { if (game === 'alttpr') { const code_trans = ALTTPR_CODES @@ -150,13 +150,4 @@ SeedCodeInput.propTypes = { value: PropTypes.arrayOf(PropTypes.string), }; -SeedCodeInput.defaultProps = { - className: '', - game: '', - name: '', - onBlur: null, - onChange: null, - value: [], -}; - export default withTranslation()(SeedCodeInput); diff --git a/resources/js/components/tracker/Dungeons.js b/resources/js/components/tracker/Dungeons.js index 8a7e4d0..758935c 100644 --- a/resources/js/components/tracker/Dungeons.js +++ b/resources/js/components/tracker/Dungeons.js @@ -12,7 +12,7 @@ import { } from '../../helpers/tracker'; import { useTracker } from '../../hooks/tracker'; -const Dungeons = ({ columns }) => { +const Dungeons = ({ columns = 4 }) => { const { config, dungeons, state } = useTracker(); const layout = React.useMemo(() => { @@ -201,8 +201,4 @@ Dungeons.propTypes = { columns: PropTypes.number, }; -Dungeons.defaultProps = { - columns: 4, -}; - export default Dungeons; -- 2.39.2 From f88b5574ec90653f571275bf398587b00618faf3 Mon Sep 17 00:00:00 2001 From: Daniel Karbach Date: Mon, 2 Sep 2024 14:49:10 +0200 Subject: [PATCH 06/16] repair OSD ref --- resources/js/components/map/OpenSeadragon.js | 11 ++++++----- resources/js/pages/Map.js | 2 +- 2 files changed, 7 insertions(+), 6 deletions(-) diff --git a/resources/js/components/map/OpenSeadragon.js b/resources/js/components/map/OpenSeadragon.js index 36ddec1..55e9638 100644 --- a/resources/js/components/map/OpenSeadragon.js +++ b/resources/js/components/map/OpenSeadragon.js @@ -9,7 +9,7 @@ export const Context = React.createContext({}); export const useOpenSeadragon = () => React.useContext(Context); -export const Provider = React.forwardRef(({ children }, ref) => { +export const Provider = ({ children, containerRef }) => { const { activeMap } = useParams(); const navigate = useNavigate(); const [searchParams, setSearchParams] = useSearchParams(); @@ -51,10 +51,10 @@ export const Provider = React.forwardRef(({ children }, ref) => { }, [searchParams, viewer]); React.useEffect(() => { - if (!ref.current) return; + if (!containerRef.current) return; const v = OpenSeadragon({ - element: ref.current, + element: containerRef.current, preserveViewport: true, sequenceMode: true, showNavigator: true, @@ -120,7 +120,7 @@ export const Provider = React.forwardRef(({ children }, ref) => { return () => { v.destroy(); }; - }, [ref.current]); + }, [containerRef.current]); React.useEffect(() => { if (!viewer) return; @@ -159,12 +159,13 @@ export const Provider = React.forwardRef(({ children }, ref) => { return {children} ; -}); +}; Provider.displayName = 'OpenSeadragonProvider'; Provider.propTypes = { children: PropTypes.node, + containerRef: PropTypes.shape({ current: PropTypes.instanceOf(Element) }), }; export default Provider; diff --git a/resources/js/pages/Map.js b/resources/js/pages/Map.js index cd3d96d..1ffd45a 100644 --- a/resources/js/pages/Map.js +++ b/resources/js/pages/Map.js @@ -24,7 +24,7 @@ export const Component = () => { - +

{t('map.heading')} - {t(`map.${activeMap}Long`)}

-- 2.39.2 From b8bec108a7fd625282407dec6e95075b3f5ca167 Mon Sep 17 00:00:00 2001 From: Daniel Karbach Date: Mon, 2 Sep 2024 18:16:00 +0200 Subject: [PATCH 07/16] public chat bot log --- app/Http/Controllers/ChatBotLogController.php | 15 +++++ app/Http/Controllers/SitemapXmlController.php | 7 ++ app/Models/ChatBotLog.php | 11 ++++ resources/js/app/Routes.js | 7 ++ resources/js/components/channel/Link.js | 29 +++++++++ resources/js/components/chat-bot-logs/Item.js | 9 ++- resources/js/components/chat-bot-logs/List.js | 33 ++++++++-- resources/js/components/episodes/Channel.js | 13 +--- resources/js/pages/HorstieLog.js | 64 +++++++++++++++++++ routes/api.php | 2 + 10 files changed, 172 insertions(+), 18 deletions(-) create mode 100644 app/Http/Controllers/ChatBotLogController.php create mode 100644 resources/js/components/channel/Link.js create mode 100644 resources/js/pages/HorstieLog.js diff --git a/app/Http/Controllers/ChatBotLogController.php b/app/Http/Controllers/ChatBotLogController.php new file mode 100644 index 0000000..86bb690 --- /dev/null +++ b/app/Http/Controllers/ChatBotLogController.php @@ -0,0 +1,15 @@ +orderBy('created_at', 'DESC')->limit(50); + return $logs->get()->toJson(); + } + +} diff --git a/app/Http/Controllers/SitemapXmlController.php b/app/Http/Controllers/SitemapXmlController.php index c538bc4..f85e40e 100644 --- a/app/Http/Controllers/SitemapXmlController.php +++ b/app/Http/Controllers/SitemapXmlController.php @@ -76,6 +76,13 @@ class SitemapXmlController extends Controller $urls[] = $url; } + $url = new SitemapUrl(); + $url->path = '/horstielog'; + $url->lastmod = ChatBotLog::latest()->first()->created_at; + $url->changefreq = 'daily'; + $url->priority = 0.5; + $urls[] = $url; + return response()->view('sitemap', [ 'urls' => $urls, ])->header('Content-Type', 'text/xml'); diff --git a/app/Models/ChatBotLog.php b/app/Models/ChatBotLog.php index a4f1f93..2819ee0 100644 --- a/app/Models/ChatBotLog.php +++ b/app/Models/ChatBotLog.php @@ -2,13 +2,24 @@ namespace App\Models; +use Illuminate\Broadcasting\Channel as PublicChannel; +use Illuminate\Database\Eloquent\BroadcastsEvents; use Illuminate\Database\Eloquent\Factories\HasFactory; use Illuminate\Database\Eloquent\Model; class ChatBotLog extends Model { + use BroadcastsEvents; use HasFactory; + public function broadcastOn($event) { + return new PublicChannel('ChatBotLog'); + } + + public function broadcastWith($event) { + $this->load(['channel', 'origin', 'user']); + } + public function channel() { return $this->belongsTo(Channel::class); } diff --git a/resources/js/app/Routes.js b/resources/js/app/Routes.js index 0e35ddb..5e12004 100644 --- a/resources/js/app/Routes.js +++ b/resources/js/app/Routes.js @@ -53,6 +53,13 @@ const router = createBrowserRouter( '../pages/AlttpSeed' )} /> + import( + /* webpackChunkName: "horstie" */ + '../pages/HorstieLog' + )} + /> } diff --git a/resources/js/components/channel/Link.js b/resources/js/components/channel/Link.js new file mode 100644 index 0000000..cb6cb79 --- /dev/null +++ b/resources/js/components/channel/Link.js @@ -0,0 +1,29 @@ +import PropTypes from 'prop-types'; +import React from 'react'; +import { Button } from 'react-bootstrap'; + +import Icon from '../common/Icon'; + +const Link = ({ channel }) => { + return ; +}; + +Link.propTypes = { + channel: PropTypes.shape({ + short_name: PropTypes.string, + stream_link: PropTypes.string, + title: PropTypes.string, + }), +}; + +export default Link; diff --git a/resources/js/components/chat-bot-logs/Item.js b/resources/js/components/chat-bot-logs/Item.js index 4c55c59..9b4cfcb 100644 --- a/resources/js/components/chat-bot-logs/Item.js +++ b/resources/js/components/chat-bot-logs/Item.js @@ -4,6 +4,7 @@ import React from 'react'; import { ListGroup } from 'react-bootstrap'; import { useTranslation } from 'react-i18next'; +import ChannelLink from '../channel/Link'; import { getUserName } from '../../helpers/User'; const getEntryDate = entry => moment(entry.created_at).fromNow(); @@ -42,7 +43,7 @@ const getEntryInfo = (entry, t) => { const Item = ({ entry = {} }) => { const { t } = useTranslation(); - return + return
{entry.text} @@ -61,11 +62,17 @@ const Item = ({ entry = {} }) => { {getEntryInfo(entry, t)}
+ {entry.channel ? +
+ +
+ : null}
; }; Item.propTypes = { entry: PropTypes.shape({ + channel: PropTypes.shape({}), created_at: PropTypes.string, origin: PropTypes.shape({}), text: PropTypes.string, diff --git a/resources/js/components/chat-bot-logs/List.js b/resources/js/components/chat-bot-logs/List.js index 0411299..52a4de8 100644 --- a/resources/js/components/chat-bot-logs/List.js +++ b/resources/js/components/chat-bot-logs/List.js @@ -4,16 +4,37 @@ import { ListGroup } from 'react-bootstrap'; import Item from './Item'; -const List = ({ log = [] }) => - - {log ? log.map(entry => - - ) : null} - ; +class List extends React.Component { + + componentDidMount() { + this.timer = setInterval(() => { + this.forceUpdate(); + }, 30000); + } + + componentWillUnmount() { + clearInterval(this.timer); + } + + render() { + const { log } = this.props; + + return + {log ? log.map(entry => + + ) : null} + ; + } + +} List.propTypes = { log: PropTypes.arrayOf(PropTypes.shape({ })), }; +List.defaultProps = { + log: [], +}; + export default List; diff --git a/resources/js/components/episodes/Channel.js b/resources/js/components/episodes/Channel.js index e2d25d7..24569be 100644 --- a/resources/js/components/episodes/Channel.js +++ b/resources/js/components/episodes/Channel.js @@ -2,6 +2,7 @@ import PropTypes from 'prop-types'; import React from 'react'; import { Button } from 'react-bootstrap'; +import Link from '../channel/Link'; import Icon from '../common/Icon'; import { mayEditRestream } from '../../helpers/permissions'; import { useUser } from '../../hooks/user'; @@ -10,17 +11,7 @@ const Channel = ({ channel, episode, onEditRestream }) => { const { user } = useUser(); return
- + {onEditRestream && mayEditRestream(user, episode, channel) ? +
+
+ {showContext ? +
+ {contextLoading ? + + : null} + {context ? + + +

{t('chatBotLog.context')}

+ + + {context.original ? + +

{t('chatBotLog.originalContext')}

+ + + : null} +
+ : null}
: null} ; diff --git a/resources/js/components/chat-logs/Item.js b/resources/js/components/chat-logs/Item.js new file mode 100644 index 0000000..52110e3 --- /dev/null +++ b/resources/js/components/chat-logs/Item.js @@ -0,0 +1,53 @@ +import PropTypes from 'prop-types'; +import React from 'react'; +import { useTranslation } from 'react-i18next'; + +const getChatterColor = entry => { + if (entry.tags && entry.tags['color']) { + return entry.tags['color']; + } + return 'inherit'; +}; + +const getChatterNick = entry => { + if (entry.tags && entry.tags['display-name']) { + return entry.tags['display-name']; + } + return entry.nick; +}; + +const getTextContent = entry => { + if (entry.params && entry.params.length >= 2) { + return entry.params[1]; + } + return entry.text_content; +}; + +const getTimestamp = entry => { + if (entry.tags && entry.tags['tmi-sent-ts']) { + return new Date(parseInt(entry.tags['tmi-sent-ts'], 10)); + } + return new Date(entry.created_at); +}; + +const Item = ({ entry }) => { + const { t } = useTranslation(); + + return
+
+ + {t('chatBotLog.shortTimestamp', { date: getTimestamp(entry) })} + + {getChatterNick(entry)} +
+
{getTextContent(entry)}
+
; +}; + +Item.propTypes = { + entry: PropTypes.shape({ + text_content: PropTypes.string, + }).isRequired, +}; + +export default Item; diff --git a/resources/js/components/chat-logs/List.js b/resources/js/components/chat-logs/List.js new file mode 100644 index 0000000..8da17e2 --- /dev/null +++ b/resources/js/components/chat-logs/List.js @@ -0,0 +1,19 @@ +import PropTypes from 'prop-types'; +import React from 'react'; + +import Item from './Item'; + +const List = ({ log = [] }) => { + return
+ {log.map(entry => + + )} +
; +}; + +List.propTypes = { + log: PropTypes.arrayOf(PropTypes.shape({ + })), +}; + +export default List; diff --git a/resources/js/i18n/de.js b/resources/js/i18n/de.js index ce3faa6..3e32cee 100644 --- a/resources/js/i18n/de.js +++ b/resources/js/i18n/de.js @@ -98,6 +98,7 @@ export default { unset: 'Zurücksetzen', }, chatBotLog: { + context: 'Kontext', empty: 'Noch keine Nachrichten erfasst', heading: 'Chat Bot Protokoll', info: { @@ -108,6 +109,9 @@ export default { origin: { chatLog: 'Quelle: {{ nick }} in {{ channel }} am {{ date, L LT }}', }, + originalContext: 'Ursprünglicher Kontext', + shortTimestamp: '{{ date, HH:mm:ss }}', + showContext: 'Kontext zeigen', }, content: { attribution: 'Attribution', diff --git a/resources/js/i18n/en.js b/resources/js/i18n/en.js index afd1aa1..b8d8721 100644 --- a/resources/js/i18n/en.js +++ b/resources/js/i18n/en.js @@ -98,6 +98,7 @@ export default { unset: 'Unset', }, chatBotLog: { + context: 'Context', empty: 'No messages on protocol yet', heading: 'Chat Bot Log', info: { @@ -108,6 +109,9 @@ export default { origin: { chatLog: 'Source: {{ nick }} in {{ channel }} on {{ date, L LT }}', }, + originalContext: 'Original context', + shortTimestamp: '{{ date, hh:mm:ss }}', + showContext: 'Show context', }, content: { attribution: 'Attribution', diff --git a/resources/sass/app.scss b/resources/sass/app.scss index 7554a9e..910d382 100644 --- a/resources/sass/app.scss +++ b/resources/sass/app.scss @@ -7,6 +7,7 @@ // Custom @import 'common'; @import 'channels'; +@import 'chatlog'; @import 'discord'; @import 'doors'; @import 'episodes'; diff --git a/resources/sass/chatlog.scss b/resources/sass/chatlog.scss new file mode 100644 index 0000000..63f9a00 --- /dev/null +++ b/resources/sass/chatlog.scss @@ -0,0 +1,4 @@ +.chat-log-list { + padding: 0.5ex 1ex; + background: $dark; +} diff --git a/routes/api.php b/routes/api.php index e3ced1d..2818414 100644 --- a/routes/api.php +++ b/routes/api.php @@ -40,6 +40,7 @@ Route::put('channels/{channel}/guessing-game/{name}', 'App\Http\Controllers\Chan Route::get('guessing-game-monitor/{key}', 'App\Http\Controllers\ChannelController@getGuessingGameMonitor'); Route::get('chatbotlogs', 'App\Http\Controllers\ChatBotLogController@search'); +Route::get('chatbotlogs/{entry}/context', 'App\Http\Controllers\ChatBotLogController@getContext'); Route::get('content', 'App\Http\Controllers\TechniqueController@search'); Route::get('content/{tech:name}', 'App\Http\Controllers\TechniqueController@single'); -- 2.39.2 From 6cc05f0394ce36ba3298a76afe46e973ae9a7ab5 Mon Sep 17 00:00:00 2001 From: Daniel Karbach Date: Tue, 10 Sep 2024 17:08:47 +0200 Subject: [PATCH 14/16] add known bot --- app/Models/ChatLog.php | 1 + 1 file changed, 1 insertion(+) diff --git a/app/Models/ChatLog.php b/app/Models/ChatLog.php index ae4c1c8..708c0e0 100644 --- a/app/Models/ChatLog.php +++ b/app/Models/ChatLog.php @@ -114,6 +114,7 @@ class ChatLog extends Model { 'kofistreambot', 'nidbot2000', 'nightbot', + 'phnxtyrolbot', 'pokemoncommunitygame', 'sery_bot', 'speedgaming', -- 2.39.2 From 9814bbb22cc4d455a7f6bb141988ecc201b7ac2c Mon Sep 17 00:00:00 2001 From: Daniel Karbach Date: Thu, 12 Sep 2024 17:21:04 +0200 Subject: [PATCH 15/16] fix consecutive tokens --- app/TwitchBot/TokenizedMessage.php | 4 ++-- tests/Unit/TwitchBot/TokenizedMessageTest.php | 4 ++++ 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/app/TwitchBot/TokenizedMessage.php b/app/TwitchBot/TokenizedMessage.php index e8465fd..e33ec97 100644 --- a/app/TwitchBot/TokenizedMessage.php +++ b/app/TwitchBot/TokenizedMessage.php @@ -15,7 +15,7 @@ class TokenizedMessage { $this->text = mb_substr($text, mb_strlen($tags['reply-parent-display-name']) + 2); } $this->raw = strtolower(preg_replace('/[^\w]/u', '', $this->text)); - $this->tokens = array_values(array_map('trim', array_filter(preg_split('/\b/u', strtolower($this->text))))); + $this->tokens = array_values(array_filter(array_map('trim', array_filter(preg_split('/\b/u', strtolower($this->text)))))); $this->emoteless = $text; if (isset($this->tags['emotes']) && !empty($this->tags['emotes'])) { @@ -34,7 +34,7 @@ class TokenizedMessage { $this->emoteless = trim(preg_replace('/\s+/u', ' ', $this->emoteless)); } $this->emoteless_raw = strtolower(preg_replace('/[^\w]/u', '', $this->emoteless)); - $this->emoteless_tokens = array_values(array_map('trim', array_filter(preg_split('/\b/u', strtolower($this->emoteless))))); + $this->emoteless_tokens = array_values(array_filter(array_map('trim', array_filter(preg_split('/\b/u', strtolower($this->emoteless)))))); } public static function fromIRC(IRCMessage $msg) { diff --git a/tests/Unit/TwitchBot/TokenizedMessageTest.php b/tests/Unit/TwitchBot/TokenizedMessageTest.php index be5da8d..3678dcc 100644 --- a/tests/Unit/TwitchBot/TokenizedMessageTest.php +++ b/tests/Unit/TwitchBot/TokenizedMessageTest.php @@ -96,4 +96,8 @@ class TokenizedMessageTest extends TestCase { $this->assertTrue(TokenizedMessage::fromString('Willkommen auf Starbase 47')->isSpammy()); } + public function test_tokenizer() { + $this->assertTrue(TokenizedMessage::fromString('@HorstieBot wie viele warps?')->hasConsecutiveTokens(['wie', 'viele'])); + $this->assertFalse(TokenizedMessage::fromString('@HorstieBot wie viele warps?')->hasConsecutiveTokens(['wo', 'wurst'])); + } } -- 2.39.2 From d6567b7d02397de40f2a0b9740703fbdb267cf51 Mon Sep 17 00:00:00 2001 From: Daniel Karbach Date: Wed, 18 Sep 2024 19:00:53 +0200 Subject: [PATCH 16/16] add known bot --- app/Models/ChatLog.php | 1 + 1 file changed, 1 insertion(+) diff --git a/app/Models/ChatLog.php b/app/Models/ChatLog.php index 708c0e0..75954b9 100644 --- a/app/Models/ChatLog.php +++ b/app/Models/ChatLog.php @@ -112,6 +112,7 @@ class ChatLog extends Model { 'fossabot', 'funtoon', 'kofistreambot', + 'lord_helmut_', 'nidbot2000', 'nightbot', 'phnxtyrolbot', -- 2.39.2