Skip to content

Commit

Permalink
Merge pull request #341 from brandonkelly/craft-3.6
Browse files Browse the repository at this point in the history
Craft 3.6 compatibility
  • Loading branch information
markhuot committed Feb 8, 2021
2 parents 2fe3ce2 + 3d2d2f3 commit ada5921
Show file tree
Hide file tree
Showing 4 changed files with 12 additions and 6 deletions.
8 changes: 7 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,12 @@
## Unreleased

### Fixed
## Unreleased

- Fixed Craft 3.6 compatibility.
- Updated graphql-php to v14.

## 1.3.5 - 2020-08-14

- Fixed Craft 3.5 compatibility. ([#338](https://github.com/markhuot/craftql/issues/338))

## 1.3.4 - 2019-08-29
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -412,7 +412,7 @@ No software is ever done. There's a lot still to do in order to make _CraftQL_ f

## Requirements

- Craft 3.2.0+
- Craft 3.6.0+
- PHP 7.0+

## Installation
Expand Down
4 changes: 2 additions & 2 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,8 @@
"craft-plugin"
],
"require": {
"craftcms/cms": "^3.2.0",
"webonyx/graphql-php": "^0.12.0",
"craftcms/cms": "^3.6.0",
"webonyx/graphql-php": "^14.4.1",
"react/http": "^0.7"
},
"authors": [
Expand Down
4 changes: 2 additions & 2 deletions src/Services/GraphQLService.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@

use Craft;
use GraphQL\GraphQL;
use GraphQL\Error\Debug;
use GraphQL\Error\DebugFlag;
use GraphQL\Type\Schema;
use GraphQL\Validator\DocumentValidator;
use GraphQL\Validator\Rules\QueryComplexity;
Expand Down Expand Up @@ -128,7 +128,7 @@ function getSchema($token) {
}

function execute($schema, $input, $variables = []) {
$debug = Craft::$app->config->getGeneral()->devMode ? Debug::INCLUDE_DEBUG_MESSAGE | Debug::RETHROW_INTERNAL_EXCEPTIONS : null;
$debug = Craft::$app->config->getGeneral()->devMode ? DebugFlag::INCLUDE_DEBUG_MESSAGE | DebugFlag::RETHROW_INTERNAL_EXCEPTIONS : null;
return GraphQL::executeQuery($schema, $input, null, null, $variables)->toArray($debug);
}

Expand Down

0 comments on commit ada5921

Please sign in to comment.