mirror of
https://git.sr.ht/~adnano/kiln
synced 2024-10-30 01:13:08 +00:00
templates: Return error from LoadTemplate
This commit is contained in:
parent
b6614b71da
commit
70cc182bf1
|
@ -119,7 +119,9 @@ func (t *Templates) Load(dir string, exts []string) error {
|
|||
}
|
||||
if d.Type().IsRegular() {
|
||||
name := strings.TrimPrefix(path, dir)
|
||||
t.LoadTemplate(name, path)
|
||||
if err := t.LoadTemplate(name, path); err != nil {
|
||||
return err
|
||||
}
|
||||
}
|
||||
return nil
|
||||
})
|
||||
|
|
Loading…
Reference in a new issue