Run vet and lint. Make us lint clean.

This commit is contained in:
Jakob Borg
2015-04-28 22:32:10 +02:00
parent 3932884688
commit 60fcaebfdb
25 changed files with 189 additions and 133 deletions

View File

@@ -27,7 +27,6 @@ type Interval struct {
end int64
}
// The type holds our configuration
type Staggered struct {
versionsPath string
cleanInterval int64
@@ -62,7 +61,6 @@ func (v Staggered) renameOld() {
}
}
// The constructor function takes a map of parameters and creates the type.
func NewStaggered(folderID, folderPath string, params map[string]string) Versioner {
maxAge, err := strconv.ParseInt(params["maxAge"], 10, 0)
if err != nil {
@@ -271,8 +269,8 @@ func (v Staggered) expire(versions []string) {
}
}
// Move away the named file to a version archive. If this function returns
// nil, the named file does not exist any more (has been archived).
// Archive moves the named file away to a version archive. If this function
// returns nil, the named file does not exist any more (has been archived).
func (v Staggered) Archive(filePath string) error {
if debug {
l.Debugln("Waiting for lock on ", v.versionsPath)