diff --git a/src/clj_jtwig/core.clj b/src/clj_jtwig/core.clj index 4e15b23..153e224 100644 --- a/src/clj_jtwig/core.clj +++ b/src/clj_jtwig/core.clj @@ -19,7 +19,7 @@ [] (reset! functions (create-function-repository))) -(defn- twig-fn-exists? [name] +(defn function-exists? [name] (try (.retrieve @functions name) true @@ -32,7 +32,7 @@ to the template." [fn-name args & body] `(do - (if (twig-fn-exists? ~fn-name) + (if (function-exists? ~fn-name) (throw (new Exception (str "JTwig template function \"" ~fn-name "\" already defined."))) (let [func# (fn ~args ~@body) handler# (reify JtwigFunction