aboutsummaryrefslogtreecommitdiff
path: root/lisp/mastodon-auth.el
diff options
context:
space:
mode:
authormousebot <mousebot@riseup.net>2021-10-03 21:40:39 +0200
committermousebot <mousebot@riseup.net>2021-10-03 21:40:39 +0200
commit7b2dd904c73b75f3c653db193c85ba61ff9642ca (patch)
tree7e54fa18bbb472a380e6035e8de1133f33c2d641 /lisp/mastodon-auth.el
parent23c61a59242fcf68ab1cc2b7fcc620b59fe11704 (diff)
flycheck: docstrings, autoloads, etc
Diffstat (limited to 'lisp/mastodon-auth.el')
-rw-r--r--lisp/mastodon-auth.el8
1 files changed, 5 insertions, 3 deletions
diff --git a/lisp/mastodon-auth.el b/lisp/mastodon-auth.el
index 3f4ee7d..0b0c703 100644
--- a/lisp/mastodon-auth.el
+++ b/lisp/mastodon-auth.el
@@ -124,7 +124,7 @@ Reads and/or stores secrets in `MASTODON-AUTH-SOURCE-FILE'."
(json-read-from-string json-string))))
(defun mastodon-auth--access-token ()
- "If an access token for the current `mastodon-instance-url' exists in `mastodon-auth--token-alist', return it.
+ "If an access token for `mastodon-instance-url' is in `mastodon-auth--token-alist', return it.
Otherwise, generate a token and pass it to `mastodon-auth--handle-token-reponse'."
(if-let ((token (cdr (assoc mastodon-instance-url mastodon-auth--token-alist))))
@@ -133,7 +133,9 @@ Otherwise, generate a token and pass it to `mastodon-auth--handle-token-reponse'
(mastodon-auth--handle-token-response (mastodon-auth--get-token))))
(defun mastodon-auth--handle-token-response (response)
- "Add the token in RESPONSE returned by `mastodon-auth--get-token' in `mastodon-auth--token-alist'.
+ "Add token RESPONSE to `mastodon-auth--token-alist'.
+
+The token is returned by `mastodon-auth--get-token'.
Handle any errors from the server."
(pcase response
@@ -143,7 +145,7 @@ Handle any errors from the server."
mastodon-auth--token-alist)))
(`(:error ,class :error_description ,error)
- (error "mastodon-auth--access-token: %s: %s" class error))
+ (error "Mastodon-auth--access-token: %s: %s" class error))
(_ (error "Unknown response from mastodon-auth--get-token!"))))