Change input path handling

Update input path to fix weird windows issues for a user.
This commit is contained in:
BuyMyMojo 2022-09-21 23:39:37 +10:00
parent b3f48957b1
commit a28999f92f
No known key found for this signature in database
GPG key ID: F2832F5012FA5B62

View file

@ -61,9 +61,17 @@ func main() {
// For each file in folder
for _, file := range files {
if !file.IsDir() {
process(CsvInput + file.Name())
}
// file is not a directory so process it's full path
// check if windows or linux
if strings.Contains(CsvInput, "\\") {
// windows
process(CsvInput + "\\" + file.Name())
} else {
// linux
process(CsvInput + "/" + file.Name())
}
}
}
} else {