aboutsummaryrefslogtreecommitdiff
path: root/lisp
diff options
context:
space:
mode:
Diffstat (limited to 'lisp')
-rw-r--r--lisp/mastodon-http.el4
1 files changed, 3 insertions, 1 deletions
diff --git a/lisp/mastodon-http.el b/lisp/mastodon-http.el
index cb211d4..144b446 100644
--- a/lisp/mastodon-http.el
+++ b/lisp/mastodon-http.el
@@ -126,7 +126,9 @@ Pass response buffer to CALLBACK function."
(buffer-substring-no-properties (point) (point-max))
'utf-8)))
(kill-buffer)
- (json-read-from-string json-string)))
+ (if (not (or (string= "" json-string) (equal nil json-string)))
+ (json-read-from-string json-string)
+ (message "Looks like we got no JSON from the server."))))
(defun mastodon-http--delete (url)
"Make DELETE request to URL."