From 967d2835da2a77a0f4935a2392f667e0330608c8 Mon Sep 17 00:00:00 2001 From: Holger Durer Date: Thu, 8 Mar 2018 18:06:40 +0000 Subject: Clean up code to remove compilation warnings. We used to be clean but have slipped recently. Let's clean up the code so it's easier to see real code smell warnings in the compilation. --- lisp/mastodon-toot.el | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) (limited to 'lisp/mastodon-toot.el') diff --git a/lisp/mastodon-toot.el b/lisp/mastodon-toot.el index 5db9d32..0c436b1 100644 --- a/lisp/mastodon-toot.el +++ b/lisp/mastodon-toot.el @@ -29,17 +29,23 @@ ;;; Code: -(defvar mastodon-toot--reply-to-id nil) +(defvar mastodon-instance-url) (defvar mastodon-toot--content-warning nil) +(autoload 'mastodon-auth--user-acct "mastodon-auth") (autoload 'mastodon-http--api "mastodon-http") (autoload 'mastodon-http--post "mastodon-http") (autoload 'mastodon-http--triage "mastodon-http") +(autoload 'mastodon-tl--as-string "mastodon-tl") (autoload 'mastodon-tl--field "mastodon-tl") (autoload 'mastodon-tl--goto-next-toot "mastodon-tl") (autoload 'mastodon-tl--property "mastodon-tl") (autoload 'mastodon-toot "mastodon") +(defvar mastodon-toot--reply-to-id nil + "Buffer-local variable to hold the id of the toot being replied to.") +(make-variable-buffer-local 'mastodon-toot--reply-to-id) + (defvar mastodon-toot-mode-map (let ((map (make-sparse-keymap))) (define-key map (kbd "C-c C-c") #'mastodon-toot--send) @@ -237,7 +243,6 @@ e.g. mastodon-toot--send -> Send." If REPLY-TO-ID is provided, set the MASTODON-TOOT--REPLY-TO-ID var." (when reply-to-user (insert (format "%s " reply-to-user)) - (make-variable-buffer-local 'mastodon-toot--reply-to-id) (setq mastodon-toot--reply-to-id reply-to-id))) (defun mastodon-toot--compose-buffer (reply-to-user reply-to-id) -- cgit v1.2.3