From 5c59792c16d1e389f0d3f117574fbad2bd531435 Mon Sep 17 00:00:00 2001 From: Radu Ioan Fericean Date: Mon, 18 Jul 2016 21:47:50 +0300 Subject: [PATCH] prevent cache file info writing by default --- utils/cache_file_info.go | 3 +++ 1 file changed, 3 insertions(+) diff --git a/utils/cache_file_info.go b/utils/cache_file_info.go index ced0c8982..5a934205e 100644 --- a/utils/cache_file_info.go +++ b/utils/cache_file_info.go @@ -40,6 +40,9 @@ func LoadCacheFileInfo(path string) (*CacheFileInfo, error) { } func SaveCacheFileInfo(path string, cfi *CacheFileInfo) error { + if path == "" { + return nil + } // open data file // create a the path if err := os.MkdirAll(path, 0766); err != nil {