0
0

fix bug, used flag direclty instead of argument

This commit is contained in:
Marty Schoch 2014-08-14 18:37:08 -04:00
parent 5dcd39ade7
commit 3efb0316d2

View File

@ -53,7 +53,7 @@ func walkDirectory(dir string) chan jsonFile {
defer close(rv) defer close(rv)
// open the directory // open the directory
dirEntries, err := ioutil.ReadDir(*jsonDir) dirEntries, err := ioutil.ReadDir(dir)
if err != nil { if err != nil {
log.Fatal(err) log.Fatal(err)
} }
@ -61,7 +61,7 @@ func walkDirectory(dir string) chan jsonFile {
// walk the directory entries // walk the directory entries
for _, dirEntry := range dirEntries { for _, dirEntry := range dirEntries {
// read the bytes // read the bytes
jsonBytes, err := ioutil.ReadFile(*jsonDir + "/" + dirEntry.Name()) jsonBytes, err := ioutil.ReadFile(dir + "/" + dirEntry.Name())
if err != nil { if err != nil {
log.Fatal(err) log.Fatal(err)
} }