anchor.diff:                (list :text "  Incorrect username or password"))))
   
   (defroute ("/login" :method :POST) (&key |username| |password|)
  -  (let ((current-user (get-user |username| |password|)))
  +  (let ((current-user (login |username| |password|)))
       (when (null current-user)
         (redirect "?error=t"))
       (unless (null current-user)
  
positive.code: ;;
  ;; Error pages
  
  (defparameter *http-error*
    '((404 . "Not Found")
      (403 . "Insufficient Permissions")))
  
  (defun error-reason (error-code)
    (cdr (assoc error-code *http-error*)))
  
  (defmethod on-exception ((app <web>) error-code)
    (declare (ignore app))
  
negative.code:   password
    groups)
  
  (defun login (username password)
    "Returns the user with the corresponding username and password"
    (with-item (and username password)
      (with-connection (db)
        (retrieve-one
         (select :*
                 (from :users)
                 (where (:and (:= :username username)
                              (:= :password (:crypt password :password)))))
         :as 'user))))
  
  ;;
  ;; General routing rules
  
  (defroute "/" ()
    (render "index.html"))
  