mirror of
https://github.com/octoleo/syncthing.git
synced 2024-11-09 23:00:58 +00:00
22 lines
292 B
Go
22 lines
292 B
Go
//+build !anal
|
|
|
|
package files
|
|
|
|
import "github.com/calmh/syncthing/scanner"
|
|
|
|
type key struct {
|
|
Name string
|
|
Version uint64
|
|
}
|
|
|
|
func keyFor(f scanner.File) key {
|
|
return key{
|
|
Name: f.Name,
|
|
Version: f.Version,
|
|
}
|
|
}
|
|
|
|
func (a key) newerThan(b key) bool {
|
|
return a.Version > b.Version
|
|
}
|