Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-pages.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBrian Williams <bwilliams@gitlab.com>2021-11-15 19:02:24 +0300
committerfeistel <6742251-feistel@users.noreply.gitlab.com>2021-11-15 19:11:10 +0300
commita725e05185fab183f8093c0358c4807f032af565 (patch)
tree9e96187f094a6163f4d01dde0ea01e277ab6d29a
parent21d4982318b198624dbcef5fb31f22b3b77d2b62 (diff)
refactor: provide more context for symlink errors
-rw-r--r--internal/vfs/local/vfs.go3
1 files changed, 2 insertions, 1 deletions
diff --git a/internal/vfs/local/vfs.go b/internal/vfs/local/vfs.go
index 6b13b541..ab757ed6 100644
--- a/internal/vfs/local/vfs.go
+++ b/internal/vfs/local/vfs.go
@@ -3,6 +3,7 @@ package local
import (
"context"
"errors"
+ "fmt"
"os"
"path/filepath"
@@ -22,7 +23,7 @@ func (localFs VFS) Root(ctx context.Context, path string, cacheKey string) (vfs.
rootPath, err = filepath.EvalSymlinks(rootPath)
if err != nil {
- return nil, err
+ return nil, fmt.Errorf("could not evaluate symlinks: %w", err)
}
fi, err := os.Lstat(rootPath)