From a6a470f8aa998f4d6a5766473d7f34440404d810 Mon Sep 17 00:00:00 2001
From: Jonas Leder <jonas@jonasled.de>
Date: Thu, 7 Apr 2022 09:12:38 +0200
Subject: [PATCH] use mutation query

---
 js/customElements/newComment.js | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/js/customElements/newComment.js b/js/customElements/newComment.js
index 99defa7..54f0e4b 100644
--- a/js/customElements/newComment.js
+++ b/js/customElements/newComment.js
@@ -105,7 +105,7 @@ class newComment extends HTMLElement {
                 }
 
                 var graphql = JSON.stringify({
-                    query: 'query($article: String!, $name: String!, $hCaptchaResponse: String!, $email: String!, $comment: String!) { newComment(article: $article, name: $name, email: $email, comment: $comment, hCaptchaResponse: $hCaptchaResponse)}',
+                    query: 'mutation($article: String!, $name: String!, $hCaptchaResponse: String!, $email: String!, $comment: String!) { newComment(article: $article, name: $name, email: $email, comment: $comment, hCaptchaResponse: $hCaptchaResponse)}',
                     variables: {
                         "article": pageName,
                         "name": nameInput.value,
-- 
GitLab