 (defvar doom-store-dir (concat doom-etc-dir "store/")
   "Directory to look for and store data accessed through this API.")
 
-(defvar doom-store-persist-alist '(t)
+(defvar doom-store-persist-alist ()
   "An alist of alists, containing lists of variables for the doom cache library
 to persist across Emacs sessions.")
 

          (puthash location (make-hash-table :test 'equal)
                   doom--store-table)))))

(defun doom--store-get (key location &optional default-value)
  (let* ((location-data (doom--store-init location))
         (data (gethash key location-data default-value)))
    (if (and (not (eq data default-value))
             (or (null (car data))
                 (not (time-less-p (car data) (current-time)))))
        (cdr data)
      default-value)))

(defun doom--store-put (key value location &optional ttl)
  (puthash key (cons (if ttl (time-add (current-time) ttl)) value)
           (doom--store-init location))
  (doom--store-flush location))

(defun doom--store-flush (location)
  (unless doom--inhibit-flush
    (let ((file-name-handler-alist nil)
          (coding-system-for-write 'binary)
          (write-region-annotate-functions nil)
          (write-region-post-annotation-function nil)
          (data (doom--store-init location)))
      (make-directory doom-store-dir 'parents)
      (with-temp-file (expand-file-name location doom-store-dir)
        (prin1 data (current-buffer)))
      data)))


;;;###autoload
(defun doom-store-get (key &optional location default-value)
  "Retrieve KEY from LOCATION (defaults to `doom-store-location').
If it doesn't exist or has expired, DEFAULT_VALUE is returned."
  (doom--store-get key (or location doom-store-location) default-value))

;;;###autoload
(defun doom-store-put (key value &optional ttl location)
  "Set KEY to VALUE in the store at LOCATION.
KEY can be any lisp object that is comparable with `equal'. TTL is the duration
(in seconds) after which this cache entry expires; if nil, no cache expiration.
LOCATION is the super-key to store this cache item under. It defaults to
`doom-store-location'."
  (doom--store-put key value (or location doom-store-location) ttl))

;;;###autoload
(defun doom-store-rem (key &optional location)
  "Clear a cache LOCATION (defaults to `doom-store-location')."
  (let ((location (or location doom-store-location)))
    (remhash key (doom--store-init location))
    (let ((table (doom--store-init "default")))
      (remhash 'test table)
      table)
    (doom--store-flush location)))

;;;###autoload
(defun doom-store-member-p (key &optional location)

    (delq! location doom-store-persist-alist 'assoc)))

(defun doom--store-init (location)
  (cl-check-type location (or null string))
  (or (gethash location doom--store-table)
      (let* ((file-name-handler-alist nil)
             (location-path (expand-file-name location doom-store-dir)))
