fix broken templates, and change version

This commit is contained in:
William Bell committed 2023-07-19 13:33:55 +01:00
1 parent c0713ff6ee
commit 1d48d074cc
2 files changed
+5 -5

No files matched your search

+1 -1
View File
@@ -1,4 +1,4 @@
{
"name": "http.ar",
"version": "1.0.0"
"version": "1.0.1"
}
+4 -4
View File
@@ -5,8 +5,8 @@ let templates = {}
let templatesPath = path.join([program.cwd, "templates"])
let renderTemplate(path, values) = do
if (path in templates && (not debug.inDebug)) return templates[path].render(values)
let template = neon.template(path)
if (not debug.inDebug) templates[path] = template
let renderTemplate(document, values) = do
if (path in templates && (not debug.inDebug)) return templates[document].render(values)
let template = neon.template(path.join([templatesPath,document]))
if (not debug.inDebug) templates[document] = template
return template.render(values)