Updated to use NAMES for files and directories instead of IDs for readability