loader/file.go
func (l *FileTemplateFetcher) FetchTemplate(path string) (TemplateSource, error) {
	if filepath.IsAbs(path) {
		return nil, ErrAbsolutePathNotAllowed
	}

	for _, dir := range l.Paths {
		fullpath := filepath.Join(dir, path)

		_, err := os.Stat(fullpath)
		if err != nil {
			continue
		}

		return NewFileSource(fullpath), nil
	}
	return nil, ErrTemplateNotFound
}
func (l *FileTemplateFetcher) FetchTemplate(path string) (TemplateSource, error) {
	if filepath.IsAbs(path) {
		return nil, ErrAbsolutePathNotAllowed
	}

	for _, dir := range l.Paths {
		fullpath := filepath.Join(dir, path)

		_, err := os.Stat(fullpath)
		if err != nil {
			continue
		}

		return NewFileSource(fullpath), nil
	}
	return nil, ErrTemplateNotFound
}
// FetchTemplate returns a TemplateSource representing the template at path
// `path`. Paths are searched relative to the paths given to NewFileTemplateFetcher()