mirror of
https://github.com/ajeetdsouza/zoxide.git
synced 2026-11-06 12:50:31 -04:00
docs: fix the complexity claim on Database::remove (#1344)
Co-authored-by: Ajeet D'Souza <98ajeet@gmail.com>
This commit is contained in:
co-authored by
Ajeet D'Souza
parent
0601783346
commit
a053d91121
+1
-1
@@ -128,7 +128,7 @@ impl Database {
|
||||
}
|
||||
|
||||
/// Removes the directory with `path` from the store. This does not preserve
|
||||
/// ordering, but is O(1).
|
||||
/// ordering.
|
||||
pub fn remove(&mut self, path: impl AsRef<str>) -> bool {
|
||||
match self.dirs().iter().position(|dir| dir.path == path.as_ref()) {
|
||||
Some(idx) => {
|
||||
|
||||
Reference in New Issue
Block a user