56ade3c96dd50059cc3c34417a65ce66398725b6 — William Vaughn 2 months ago 57fce2a
fix auth middleware ordering

middleware are like an onion. At definition they are wrapped, and at
runtime they run from the outside in (bottom up, in this case using ->)
1 files changed, 2 insertions(+), 2 deletions(-)

M src/clj/grsroot_auth/middleware.clj
M src/clj/grsroot_auth/middleware.clj => src/clj/grsroot_auth/middleware.clj +2 -2
@@ 56,8 56,8 @@
(defn wrap-auth [handler]
  (let [backend (backends/jws {:secret (pkey (:auth-cfg env)) :options {:alg :rs512}})]
    (-> handler
        (wrap-authentication backend)
        (wrap-authentication backend))))

(defn wrap-base [handler]
  (-> handler