Skip to content

Commit 3a71247

Browse files
authored
fix(docs): improved documentation for remove_fully (#78)
The documentation is outdated since #63. This merge request aims to update it to reflect the new changes. According to the the release notes for v13.0.0, this is meant to be a fix, but the documentation makes it looks like a bug.
1 parent c102c01 commit 3a71247

File tree

1 file changed

+7
-3
lines changed

1 file changed

+7
-3
lines changed

src/index.rs

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -393,13 +393,15 @@ impl RemoveOpts {
393393
}
394394

395395
/// Set the remove fully option
396-
/// If remove_fully is set to true then the index file itself will be physically deleted rather than appending a null.
396+
/// If remove_fully is set to true then the index and content file itself will be physically deleted rather than appending a null.
397397
pub fn remove_fully(mut self, remove_fully: bool) -> Self {
398398
self.remove_fully = remove_fully;
399399
self
400400
}
401401

402-
/// Removes an individual index metadata entry. The associated content will be left in the cache.
402+
/// Removes an individual index metadata entry.
403+
/// If remove_fully is set to false (default), the associated content will be left in the cache.
404+
/// If remove_fully is true, both the index entry and the contents will be physically removed from the disk
403405
pub fn remove_sync<P, K>(self, cache: P, key: K) -> Result<()>
404406
where
405407
P: AsRef<Path>,
@@ -419,7 +421,9 @@ impl RemoveOpts {
419421
}
420422
}
421423

422-
/// Removes an individual index metadata entry. The associated content will be left in the cache.
424+
/// Removes an individual index metadata entry.
425+
/// If remove_fully is set to false (default), the associated content will be left in the cache.
426+
/// If remove_fully is true, both the index entry and the contents will be physically removed from the disk
423427
#[cfg(any(feature = "async-std", feature = "tokio"))]
424428
pub async fn remove<P, K>(self, cache: P, key: K) -> Result<()>
425429
where

0 commit comments

Comments
 (0)