fukamachi / caveman

Lightweight web application framework for Common Lisp.
http://8arrow.org/caveman/
782 stars 63 forks source link

url-for not working properly #42

Closed lucashpandolfo closed 9 years ago

lucashpandolfo commented 9 years ago

in v2/src/helper.lisp, url-for is being imported from myway and then redefined as:

(defun url-for (route-name &rest params)
  (let ((route (find-if #'(lambda (route)
                            (string-equal (route-name route) route-name))
                        (mapper-routes (mapper *current-app*)))))
    (if route
        (multiple-value-bind (base-url rest-params)
            (url-for route params)
          (add-query-parameters base-url rest-params))
        (error "No route found for ~S" route-name))))

The inner url-for should be the one from myway, but the redefined one is being called. Replacing the call by myway:url-for makes the function work again.

fukamachi commented 9 years ago

Thank you for reporting!