2006-10-25 OHASHI Akira <bg66@koka-in.org>
+ * mixi.el (mixi-cache-expires): Add new constant.
+ (mixi-cache-expired-p): Follow the change above.
+
+2006-10-25 OHASHI Akira <bg66@koka-in.org>
+
* mixi.el (mixi-retrieve-function): Use `radio' instead of `choice'.
(mixi-default-email): Ditto.
(mixi-default-password): Ditto.
(defcustom mixi-cache-expires 3600
"*Seconds for expiration of a cached object."
:type '(radio (integer :tag "Expired seconds")
- (const :tag "Don't expire" nil))
+ (const :tag "Don't expire" nil)
+ (const :tag "Don't cache" t))
:group 'mixi)
;; FIXME: Not implemented.
(let ((timestamp (mixi-object-timestamp object)))
(unless (or (null mixi-cache-expires)
(null timestamp))
- (mixi-time-less-p
- (mixi-time-add timestamp (mixi-seconds-to-time mixi-cache-expires))
- (current-time)))))
+ (if (numberp mixi-cache-expires)
+ (mixi-time-less-p
+ (mixi-time-add timestamp (mixi-seconds-to-time mixi-cache-expires))
+ (current-time))
+ t))))
(defun mixi-make-cache (key value table)
"Make a cache object and return it."