Add some debugging output for {create,retrieve,delete}
This commit is contained in:
parent
d85f985694
commit
00ccc22ef5
1 changed files with 3 additions and 0 deletions
|
@ -130,6 +130,7 @@ impl Store {
|
|||
/// Creates the Entry at the given location (inside the entry)
|
||||
pub fn create<'a>(&'a self, id: StoreId) -> Result<FileLockEntry<'a>> {
|
||||
if !self.id_in_store(&id) {
|
||||
debug!("'{:?}' seems not to be in '{:?}'", id, self.location);
|
||||
return Err(StoreError::new(StoreErrorKind::StorePathOutsideStore, None));
|
||||
}
|
||||
|
||||
|
@ -153,6 +154,7 @@ impl Store {
|
|||
/// dropped, the new Entry is written to disk
|
||||
pub fn retrieve<'a>(&'a self, id: StoreId) -> Result<FileLockEntry<'a>> {
|
||||
if !self.id_in_store(&id) {
|
||||
debug!("'{:?}' seems not to be in '{:?}'", id, self.location);
|
||||
return Err(StoreError::new(StoreErrorKind::StorePathOutsideStore, None));
|
||||
}
|
||||
|
||||
|
@ -213,6 +215,7 @@ impl Store {
|
|||
/// Delete an entry
|
||||
pub fn delete(&self, id: StoreId) -> Result<()> {
|
||||
if !self.id_in_store(&id) {
|
||||
debug!("'{:?}' seems not to be in '{:?}'", id, self.location);
|
||||
return Err(StoreError::new(StoreErrorKind::StorePathOutsideStore, None));
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue