From f7127d6ce13740092b4adbb01a1454f3f9d4624f Mon Sep 17 00:00:00 2001 From: Coder <161350311+MamunC0der@users.noreply.github.com> Date: Mon, 20 Oct 2025 15:30:04 +0200 Subject: [PATCH] Update path.go --- common/path.go | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/common/path.go b/common/path.go index 49c6a5efc2..4b46bdfd43 100644 --- a/common/path.go +++ b/common/path.go @@ -24,10 +24,7 @@ import ( // FileExist checks if a file exists at filePath. func FileExist(filePath string) bool { _, err := os.Stat(filePath) - if err != nil && os.IsNotExist(err) { - return false - } - return true + return !os.IsNotExist(err) } // AbsolutePath returns datadir + filename, or filename if it is absolute.