diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/endpoint.lisp | 29 |
1 files changed, 1 insertions, 28 deletions
diff --git a/src/endpoint.lisp b/src/endpoint.lisp index 103d86b..73aaa6f 100644 --- a/src/endpoint.lisp +++ b/src/endpoint.lisp @@ -83,12 +83,6 @@ keyword arguments to make-instance for CLASS." :documentation "Function in HUNCHENTOOT:*DISPATCH-TABLE*. (Re)defined whenever an instance of this class is defined.") - (body-type - :reader body-type - :initarg :body-type - :initform nil - :type (or null string) - :documentation "The mimetype of the body for requests that have them.") (want-body-stream :reader want-body-stream :initarg :want-stream @@ -182,23 +176,6 @@ association list keyed by strings." type." type)) (setf (gethash type *mimetype-parsers*) function)) -(define-condition unregistered-body-type (warning) - ((type :initarg :mimetype :type string) - (class :initarg :class :type symbol)) - (:report - (lambda (c s) - (with-slots (type class) c - (format s - " -Class ~a was defined with body type ~a, but no parser has been -registered for that body type. - -Check your spelling or call - (REGEISTER-BODY-PARSER ~s <your function>) -" - class type type))))) - - ;;; INSTANCE CLASS INITIALIZATION LOGIC (defun route-matching-regex (parts) @@ -260,14 +237,10 @@ extractors." part)))) Good for indicating that you've got a bonkers class option syntax" (assert (slot-boundp class 'route) (class) "ROUTE must be bound") (with-slots - (route extractors method body-type want-body-stream content-type) + (route extractors method want-body-stream content-type) class (check-type route string "a regex STRING.") (check-type method http-method "an HTTP-METHOD keyword") - (when body-type - (unless (or (pre-parsed-body-p body-type) - (lookup-body-parser body-type)) - (warn 'unregistered-body-type :type body-type :class (class-name class)))) (check-type want-body-stream boolean "a BOOLEAN") (check-type content-type string "a STRING mimetype") (loop |