Browse Source

Expose a bit more information about needed file in REST interface

Jakob Borg 11 years ago
parent
commit
1139ea2c81
1 changed files with 8 additions and 4 deletions
  1. 8 4
      cmd/syncthing/gui.go

+ 8 - 4
cmd/syncthing/gui.go

@@ -119,12 +119,16 @@ type guiFile scanner.File
 
 func (f guiFile) MarshalJSON() ([]byte, error) {
 	type t struct {
-		Name string
-		Size int64
+		Name     string
+		Size     int64
+		Modified int64
+		Flags    uint32
 	}
 	return json.Marshal(t{
-		Name: f.Name,
-		Size: scanner.File(f).Size,
+		Name:     f.Name,
+		Size:     scanner.File(f).Size,
+		Modified: f.Modified,
+		Flags:    f.Flags,
 	})
 }