changed index to home and directory to index