Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[NEXT] Add support for Laravel 8 #672

Merged
merged 4 commits into from
Sep 2, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 6 additions & 1 deletion .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,11 @@ jobs:
strategy:
matrix:
php: [7.2, 7.3, 7.4]
laravel: [^6.0, ^7.0]
laravel: [^6.0, ^7.0, ^8.0]
lazy_types: ['false', 'true']
exclude:
- php: 7.2
laravel: ^8.0
name: P=${{ matrix.php }} L=${{ matrix.laravel }} Lazy types=${{ matrix.lazy_types }}
runs-on: ubuntu-18.04
env:
Expand All @@ -27,6 +30,8 @@ jobs:
- run: composer remove --dev matt-allan/laravel-code-style --no-update
- run: composer require illuminate/contracts:${{ matrix.laravel }} --no-update
- run: composer remove --dev nunomaduro/larastan --no-update
- run: composer remove --dev laravel/legacy-factories --no-update
if: (matrix.laravel == '^6.0' || matrix.laravel == '^7.0')

- name: Get composer cache directory
id: composercache
Expand Down
3 changes: 3 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,9 @@ CHANGELOG
- Upgrade to webonxy/graphql-php 14.0.0 [\#645 / mfn](https://github.com/rebing/graphql-laravel/pull/645)
- Remove support for Laravel < 6.0 [\#651 / mfn](https://github.com/rebing/graphql-laravel/pull/651)
This also bumps the minimum required version to PHP 7.2

### Added
- Support for Laravel 8 [\#672 / mfn](https://github.com/rebing/graphql-laravel/pull/672)

2020-07-02, 5.1.2
-----------------
Expand Down
11 changes: 6 additions & 5 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -35,19 +35,20 @@
"type": "library",
"require": {
"php": ">= 7.2",
"illuminate/contracts": "^6.0|^7.0",
"illuminate/support": "^6.0|^7.0",
"illuminate/contracts": "^6.0|^7.0|^8.0",
"illuminate/support": "^6.0|^7.0|^8.0",
"webonyx/graphql-php": "^14.0",
"ext-json": "*"
},
"require-dev": {
"orchestra/testbench": "4.0.*|5.0.*",
"orchestra/testbench": "4.0.*|5.0.*|^6.0",
"phpunit/phpunit": "~7.0|~8.0",
"nunomaduro/larastan": "0.6.1",
"nunomaduro/larastan": "0.6.4",
"mockery/mockery": "^1.2",
"friendsofphp/php-cs-fixer": "^2.15",
"matt-allan/laravel-code-style": "0.5.1",
"ext-pdo_sqlite": "*"
"ext-pdo_sqlite": "*",
"laravel/legacy-factories": "^1.0"
},
"autoload": {
"psr-4": {
Expand Down
1 change: 0 additions & 1 deletion phpstan.neon.dist
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@ parameters:
- '/Parameter #3 \$subject of function str_replace expects array\|string, string\|false given/'
- '/Method Rebing\\GraphQL\\GraphQL::routeNameTransformer\(\) should return string but returns string\|null/'
- '/Cannot access property \$parameters on mixed/'
- '/Parameter #1 \$haystack of function mb_stripos expects string, \(array\)\|string given/'
- '/Strict comparison using === between null and array will always evaluate to false/'
# \Rebing\GraphQL\Support\SelectFields::handleFields
- '/Binary operation "." between string and array\|string\|null results in an error/'
Expand Down
2 changes: 1 addition & 1 deletion src/GraphQLUploadMiddleware.php
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ public function handle(Request $request, Closure $next)
*/
public function processRequest(Request $request): Request
{
$contentType = $request->header('content-type') ?: '';
$contentType = $request->headers->get('content-type') ?: '';

if (mb_stripos($contentType, 'multipart/form-data') !== false) {
$this->validateParsedBody($request);
Expand Down