From 9656457f6c00441ffed8eb6b633080a0316a4a0f Mon Sep 17 00:00:00 2001 From: Artur Malabarba Date: Sat, 18 Apr 2015 08:43:26 +0100 Subject: Generalize sx-method-post-from-data --- sx-method.el | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'sx-method.el') diff --git a/sx-method.el b/sx-method.el index e458213..065f8d6 100644 --- a/sx-method.el +++ b/sx-method.el @@ -153,8 +153,8 @@ the following which are decided by this function: :filter is `sx-browse-filter'. :auth is warn. -As a special exception, if KEYS is a single argument, it is -assumed to be the :submethod argument." +As a special exception, if the car of KEYS is not a keyword, it +is assumed to be the :submethod argument." (declare (indent 1)) (sx-assoc-let data (apply #'sx-method-call @@ -166,9 +166,9 @@ assumed to be the :submethod argument." :url-method 'post :filter sx-browse-filter :site .site_par - (if (= 1 (length keys)) - (cons :submethod keys) - keys)))) + (if (keywordp (car keys)) + keys + (cons :submethod keys))))) (provide 'sx-method) ;;; sx-method.el ends here -- cgit v1.2.3