Commits

Jason McBrayer committed a1d38ce

Support changing instapaper-api-base without reloading.

This shouldn't ever really be necessary, unless your environment is very
strange (e.g., https is blocked or your url.el doesn't support https).

Comments (0)

Files changed (1)

 (require 'browse-url)
 
 (defvar instapaper-api-base "https://www.instapaper.com/api/"
-  "Base URL for all instapaper API functions")
-(defvar instapaper-auth-url (concat instapaper-api-base "authenticate")
-  "URL for method for validating an instapaper username and password")
-(defvar instapaper-add-url (concat instapaper-api-base "add")
-  "URL for method for adding a URL to instapaper")
+  "Base URL for all instapaper API functions
+Generally, you shouldn't change this, unless your environment is notably
+strange (e.g., no https).")
 
 (defconst instapaper-version "0.9.5"
   "Version of instapaper.el")
                                    (if title (concat "title="
                                                      (url-hexify-string title) "&") nil)
                                    (if selection (concat "selection="
-                                                         (url-hexify-string selection)) nil))))
+                                                         (url-hexify-string selection)) nil)))
+         (instapaper-add-url (concat instapaper-api-base "add")))
     (message "url-request-data: %s" url-request-data)
     (if (>= emacs-major-version 24)
         (url-retrieve instapaper-add-url 'instapaper-add-callback (list url title selection) t)
Tip: Filter by directory path e.g. /media app.js to search for public/media/app.js.
Tip: Use camelCasing e.g. ProjME to search for ProjectModifiedEvent.java.
Tip: Filter by extension type e.g. /repo .js to search for all .js files in the /repo directory.
Tip: Separate your search with spaces e.g. /ssh pom.xml to search for src/ssh/pom.xml.
Tip: Use ↑ and ↓ arrow keys to navigate and return to view the file.
Tip: You can also navigate files with Ctrl+j (next) and Ctrl+k (previous) and view the file with Ctrl+o.
Tip: You can also navigate files with Alt+j (next) and Alt+k (previous) and view the file with Alt+o.