Remove useless directory check in filename-based cache busting