From 2e8c3d805690fce6d19fffb4ba024e1989c18825 Mon Sep 17 00:00:00 2001 From: colin Date: Sun, 11 Aug 2024 20:37:54 -0700 Subject: Fixes --- pastiche.lisp | 15 +++------------ 1 file changed, 3 insertions(+), 12 deletions(-) (limited to 'pastiche.lisp') diff --git a/pastiche.lisp b/pastiche.lisp index 1ca4807..e5141ae 100644 --- a/pastiche.lisp +++ b/pastiche.lisp @@ -29,7 +29,6 @@ :initform (error "Missing required slot")) ((localhost-port "Port on which the HTTP server should listen.") (service-port "Port that should be mentioned in URLs generated by the app.") - (ttl "The default time-to-live, in milliseconds") :ro :type integer :initform (error "Missing required slot")) @@ -53,9 +52,6 @@ (defun paste-path* () (paste-path *config*)) -(defun ttl* () - (ttl *config*)) - (defun load-config (path) "Loads a PLIST from disk from PATH. @@ -65,8 +61,7 @@ E.g. you'd put this in a file. :service-protocol 8989 :db-path \"/absolute/path/to/a/directory/\", :paste-path \"/absolute/path/to/another/directory/\", - :server-port 8000 - :ttl 7776000)" + :server-port 8000)" (destructuring-bind (&key service-domain @@ -74,8 +69,7 @@ E.g. you'd put this in a file. service-port localhost-port db-path - paste-path - ttl) + paste-path) (uiop:read-file-form path) (setf *config* (make-instance 'config @@ -84,8 +78,7 @@ E.g. you'd put this in a file. :service-port service-port :localhost-port localhost-port :db-path db-path - :paste-path paste-path - :ttl ttl)))) + :paste-path paste-path)))) (defun start () (unless *config* @@ -111,7 +104,6 @@ E.g. you'd put this in a file. (def:class paste (db:store-object) ((title "A name for this paste. Used to generate file name on disk.") - (content "The text of this paste") (filename "Filename relative to CONFIG's PASTE-PATH") :type string :initform (error "Missing required slot") @@ -206,7 +198,6 @@ from make-paste-filename.")) :pinned nil :privacy :unlisted :paste-time (get-universal-time) - :content content :title title :filename location)) -- cgit v1.2.3