0

我在 Laravel 中遇到以下错误

PHP 致命错误:ArrayAccess 继承期间:未捕获 ErrorException:Illuminate\Support\Collection::offsetExists($key) 的返回类型应该与 ArrayAccess::offsetExists(mixed $offset): bool 兼容,或者 #[\ReturnTypeWillChange ] 属性应该用于暂时抑制 E:\xampp\htdocs\project1\vendor\laravel\framework\src\Illuminate\Support\Collection.php:1277 中的通知

作曲家:

{
    "name": "laravel/laravel",
    "type": "project",
    "description": "The Laravel Framework.",
    "keywords": [
        "framework",
        "laravel"
    ],
    "license": "MIT",
    "require": {
        "php": "^7.2.5|^8.0",
        "ext-dom": "*",
        "ext-gd": "*",
        "ext-json": "*",
        "anhskohbo/no-captcha": "^3.2",
        "doctrine/dbal": "^2.10",
        "fideloper/proxy": "^4.0",
        "fruitcake/laravel-cors": "^2.0",
        "geoip2/geoip2": "^2.12",
        "io-developer/php-whois": "^4.1",
        "ivopetkov/html5-dom-document-php": "2.*",
        "laravel/framework": "^6.20.26",
        "laravel/tinker": "^2.5",
        "league/csv": "^9.7",
        "protonemedia/laravel-verify-new-email": "^1.1",
        "simplesoftwareio/simple-qrcode": "^4.2",
        "spatie/ssl-certificate": "^1.22",
        "stripe/stripe-php": "^7.83",
        "symfony/dom-crawler": "^5.3",
        "whichbrowser/parser": "^2.1"
    },
    "require-dev": {
        "filp/whoops": "^2.0",
        "fakerphp/faker": "^1.9.1",
        "kitloong/laravel-migrations-generator": "^4.3",
        "mockery/mockery": "^1.0",
        "nunomaduro/collision": "^3.0",
        "phpunit/phpunit": "^8.5.8|^9.3.3"
    },
    "config": {
        "optimize-autoloader": true,
        "preferred-install": "dist",
        "sort-packages": true
    },
    "extra": {
        "laravel": {
            "dont-discover": []
        }
    },
    "autoload": {
        "psr-4": {
            "App\\": "app/"
        },
        "classmap": [
            "database/seeds",
            "database/factories"
        ]
    },
    "autoload-dev": {
        "psr-4": {
            "Tests\\": "tests/"
        }
    },
    "minimum-stability": "dev",
    "prefer-stable": true,
    "scripts": {
        "post-autoload-dump": [
            "Illuminate\\Foundation\\ComposerScripts::postAutoloadDump",
            "@php artisan package:discover --ansi"
        ],
        "post-root-package-install": [
            "@php -r \"file_exists('.env') || copy('.env.example', '.env');\""
        ],
        "post-create-project-cmd": [
            "@php artisan key:generate --ansi"
        ]
    }
}

4

0 回答 0