Make sure directories are treated like files and are rigstered to handle delete envets with no file names on windows. Additionally, use delete keyword instead of nulling because we're using Object.keys to iterate over objects. Should fix #13