lib/config: Disable folder free disk check when configured (fixes #5267) (#5268)

This commit is contained in:
Simon Frei 2018-10-12 13:34:56 +02:00 committed by Audrius Butkevicius
parent 8d7ea0424d
commit 089c283ca6

View File

@ -269,6 +269,10 @@ func (f *FolderConfiguration) SharedWith(device protocol.DeviceID) bool {
}
func (f *FolderConfiguration) CheckAvailableSpace(req int64) error {
val := f.MinDiskFree.BaseValue()
if val <= 0 {
return nil
}
fs := f.Filesystem()
usage, err := fs.Usage(".")
if err != nil {