summaryrefslogtreecommitdiffstats
path: root/lib/syncthing/stfolder.go
diff options
context:
space:
mode:
authorSebastien Douheret <sebastien.douheret@iot.bzh>2017-05-22 13:51:04 +0200
committerSebastien Douheret <sebastien.douheret@iot.bzh>2017-05-22 13:51:04 +0200
commitad8f8d97a48f155ba94d5646012e969845a315ab (patch)
treeb991f09b8d08c900dd08583522a7db952ed43c79 /lib/syncthing/stfolder.go
parentfbbcd6cedc47e45f6a2aaae708be194731a0139b (diff)
Allow to set Syncthing rescanInterval parameter.
Diffstat (limited to 'lib/syncthing/stfolder.go')
-rw-r--r--lib/syncthing/stfolder.go4
1 files changed, 4 insertions, 0 deletions
diff --git a/lib/syncthing/stfolder.go b/lib/syncthing/stfolder.go
index 45ac60d..e7ee0ec 100644
--- a/lib/syncthing/stfolder.go
+++ b/lib/syncthing/stfolder.go
@@ -58,6 +58,10 @@ func (s *SyncThing) FolderChange(f xdsconfig.FolderConfig) error {
RawPath: filepath.Join(s.conf.ShareRootDir, f.RelativePath),
}
+ if s.conf.FileConf.SThgConf.RescanIntervalS > 0 {
+ folder.RescanIntervalS = s.conf.FileConf.SThgConf.RescanIntervalS
+ }
+
folder.Devices = append(folder.Devices, config.FolderDeviceConfiguration{
DeviceID: newDevice.DeviceID,
})