branch: elpa/graphql-mode
commit 1bff11f21c8c0969c557e7083277ed1ae93c7c68
Author: Tim Shiu <[email protected]>
Commit: Tim Shiu <[email protected]>
fix the line-boundary issue to enhance {} sexp
---
graphql-mode.el | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/graphql-mode.el b/graphql-mode.el
index 67ebaba4eb..14ab2774a4 100644
--- a/graphql-mode.el
+++ b/graphql-mode.el
@@ -129,9 +129,9 @@ of the variables used in the query."
(save-excursion
(let ((line (thing-at-point 'line t)))
(when (string-match-p (regexp-quote "}") line)
- (beginning-of-line))
+ (search-backward "}"))
(when (string-match-p (regexp-quote "{") line)
- (end-of-line))
+ (search-forward "{"))
(graphql-current-query))))))
(defun graphql-current-operation ()