diff --git a/pkg/files/files.go b/pkg/files/files.go index 092ed6e..fc5c3d3 100644 --- a/pkg/files/files.go +++ b/pkg/files/files.go @@ -9,7 +9,7 @@ import ( const FileDateFormat = "2006-01-02 15:04:05 MST" -type DirStats struct { +type DirStat struct { Files int64 FilesSize string Directories int64 @@ -22,7 +22,7 @@ type DirEntry struct { Size string } -func ScanDirectory(path, urlBase string) (entries []DirEntry, stats DirStats, err error) { +func ScanDirectory(path, urlBase string) (entries []DirEntry, stats DirStat, err error) { var dirEntries []DirEntry = make([]DirEntry, 0) var fileEntries []DirEntry = make([]DirEntry, 0) var totalFilesSize int64 = 0 diff --git a/web/templates/index.jade b/web/templates/index.jade index 17e6048..4a52a90 100644 --- a/web/templates/index.jade +++ b/web/templates/index.jade @@ -5,7 +5,7 @@ block nav h1 Files block content - :go:func Index(title, mainSite, currentPath string, stats *files.DirStats, items *[]files.DirEntry, r *http.Request) + :go:func Index(title, mainSite, currentPath string, stats *files.DirStat, items *[]files.DirEntry, r *http.Request) :go:import "dwelling-files/pkg/files" :go:import "dwelling-files/pkg/utils" section