Skip to content
Snippets Groups Projects
Unverified Commit b81863fb authored by Tanner Bruce's avatar Tanner Bruce
Browse files

Check error while walking environments


It is possible for the walk function to be called with err set

Signed-off-by: default avatarTanner Bruce <bruce.tanner@gmail.com>
parent f941c9d1
No related branches found
No related tags found
No related merge requests found
......@@ -211,6 +211,10 @@ func (m *manager) GetEnvironments() ([]*Environment, error) {
log.Debug("Retrieving all environments")
err := afero.Walk(m.appFS, string(m.environmentsPath), func(path string, f os.FileInfo, err error) error {
if err != nil {
log.Debugf("Failed to walk the path at '%s'", path)
return err
}
isDir, err := afero.IsDir(m.appFS, path)
if err != nil {
log.Debugf("Failed to check whether the path at '%s' is a directory", path)
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment