Refactor file lister
beginning of index fix
more work on index bug
getting closer
bug fixed!