- Issue created by @InaW
- Status changed to Needs review
10 months ago 12:26pm 18 January 2024 The error occurs where the debug button is rendered:
$context['graphql_debug'] = [ '#markup' => sprintf( '<div class="graphql-twig-debug-child"><div class="%s" data-graphql-query="%s" data-graphql-variables="%s" data-graphql-server="%s"></div></div>', 'graphql-twig-debug-wrapper', htmlspecialchars($query), htmlspecialchars(json_encode($arguments)), $this->env->getGraphQlServer()->id() ), ];
Since the method
getGraphQlServer()
does not exist in graphql_twig 3.x (but in graphql_twig 4.x does) I reverted the changes and implemented it like it was in 3.0.0-beta1 and set the from url fix to/graphql/explorer
$form = $('<form method="post" target="_blank"></form>').attr('action', Drupal.url('graphql/explorer')).appendTo(this),
- 🇩🇪Germany larskleiner
Thanks for opening the merge request. With that patch applied, I still get the following error:
Error: Cannot access protected property GraphQL\Error\Error::$message in __TwigTemplate_511eccd1dbfb90f954c68860ff9ce526->display() (line 121 of modules/contrib/graphql_twig/src/GraphQLTemplateTrait.php).
I re-rolled the patch with an additional fix for this error.
- 47523310 committed on 3.x
Issue #3404044 by InaW, larskleiner: Call to undefined method error when...
- 47523310 committed on 3.x
- Status changed to Fixed
4 months ago 1:42pm 18 July 2024 Automatically closed - issue fixed for 2 weeks with no activity.