Improve the logic for testing whether one directory is a prefix of another