Move function
This commit is contained in:
parent
1f94736771
commit
43e32338c7
2 changed files with 5 additions and 5 deletions
|
@ -10,11 +10,6 @@
|
||||||
(remove-if #'string-empty-p
|
(remove-if #'string-empty-p
|
||||||
(uiop:split-string uri :separator "/")))
|
(uiop:split-string uri :separator "/")))
|
||||||
|
|
||||||
(defun valid-survey-id-p (id)
|
|
||||||
(check-type id integer)
|
|
||||||
(let ((ids (mapcar #'car (load-response (make-surveys-db-path)))))
|
|
||||||
(if (member id ids) t nil)))
|
|
||||||
|
|
||||||
(defun today ()
|
(defun today ()
|
||||||
"Return today's date formatted as ISO-8601."
|
"Return today's date formatted as ISO-8601."
|
||||||
(local-time:format-timestring nil
|
(local-time:format-timestring nil
|
||||||
|
|
|
@ -1,5 +1,10 @@
|
||||||
(in-package :ml-survey/handlers)
|
(in-package :ml-survey/handlers)
|
||||||
|
|
||||||
|
(defun survey-id-p (id)
|
||||||
|
(check-type id integer)
|
||||||
|
(let ((ids (mapcar #'car (load-response (make-surveys-db-path)))))
|
||||||
|
(if (member id ids) t nil)))
|
||||||
|
|
||||||
(defun survey-uri-p (uri)
|
(defun survey-uri-p (uri)
|
||||||
"Check if the request URI matches the pattern '/survey/<numeric>'"
|
"Check if the request URI matches the pattern '/survey/<numeric>'"
|
||||||
(check-type uri string)
|
(check-type uri string)
|
||||||
|
|
Loading…
Add table
Reference in a new issue