[ci skip] Small nit-picking
This commit is contained in:
parent
51cf764861
commit
28a6edcaf4
|
@ -44,7 +44,7 @@ func getEntries(dirPath string) ([]Entry, error) {
|
|||
|
||||
// Output an index.html file listing entries to a specified destination
|
||||
func renderIndexHTML(entries []Entry, dest string) error {
|
||||
tmpl, err := template.New("index.html").Parse(indexTemplate)
|
||||
tmpl, err := template.New(dest).Parse(indexTemplate)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
|
@ -58,7 +58,6 @@ func renderIndexHTML(entries []Entry, dest string) error {
|
|||
Entries []Entry
|
||||
}{Path: dirPath, Entries: entries}
|
||||
|
||||
// Open the destination index.html file
|
||||
destFile, err := os.Create(path.Join(dest, "index.html"))
|
||||
if err != nil {
|
||||
return err
|
||||
|
|
Loading…
Reference in New Issue