The array which tracks the filenames of the generated HTML files contains the correct data in the last recursive parseFIle call - but when the caller function (generateWebsite which calls parseFile initially) proceeds to the next line of execution, the array that tracks the filenames is still empty — so generateIndex has no filenames to work with; thus the index.html file is not generated.
index.html file is not being generated
The array which tracks the filenames of the generated HTML files contains the correct data in the last recursive
parseFIle
call - but when the caller function (generateWebsite
which callsparseFile
initially) proceeds to the next line of execution, the array that tracks the filenames is still empty — sogenerateIndex
has no filenames to work with; thus the index.html file is not generated.