don't crash if path == base_directory.