diff --git a/src/core/index.rs b/src/core/index.rs index 4ad143219..65f00fa18 100644 --- a/src/core/index.rs +++ b/src/core/index.rs @@ -120,7 +120,7 @@ impl IndexBuilder { /// Creates a new index in a given filepath. /// The index will use the `MMapDirectory`. /// - /// If a previous index was in this directory, then its meta file will be destroyed. + /// If a previous index was in this directory, it returns an `IndexAlreadyExists` error. #[cfg(feature = "mmap")] pub fn create_in_dir>(self, directory_path: P) -> crate::Result { let mmap_directory = MmapDirectory::open(directory_path)?; @@ -238,7 +238,7 @@ impl Index { /// Creates a new index in a given filepath. /// The index will use the `MMapDirectory`. /// - /// If a previous index was in this directory, then its meta file will be destroyed. + /// If a previous index was in this directory, then it returns an `IndexAlreadyExists` error. #[cfg(feature = "mmap")] pub fn create_in_dir>( directory_path: P,