Skip to content

Commit a961e27

Browse files
committed
Go: Initialise filesToRemove to an empty array
1 parent 51eb487 commit a961e27

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

go/extractor/project/project.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -110,7 +110,7 @@ func checkDirsNested(inputDirs []string) (string, bool) {
110110
}
111111

112112
// A list of files we created that should be removed after we are done.
113-
var filesToRemove []string
113+
var filesToRemove []string = []string{}
114114

115115
// Try to initialize a go.mod file for projects that do not already have one.
116116
func initGoModForLegacyProject(path string) {
@@ -148,7 +148,7 @@ func RemoveTemporaryExtractorFiles() {
148148
}
149149
}
150150

151-
filesToRemove = nil
151+
filesToRemove = []string{}
152152
}
153153

154154
// Find all go.work files in the working directory and its subdirectories

0 commit comments

Comments
 (0)