mirror of
https://github.com/packwiz/packwiz.git
synced 2025-04-19 21:16:30 +02:00
End path walk when an error is encountered in detect command, fixes nil pointer deref
This commit is contained in:
parent
bd9f5dbebc
commit
f1009a3289
@ -35,6 +35,9 @@ var detectCmd = &cobra.Command{
|
||||
var hashes []int
|
||||
modPaths := make(map[int]string)
|
||||
err = filepath.Walk("mods", func(path string, info os.FileInfo, err error) error {
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
if info.IsDir() {
|
||||
return nil
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user