(
&mut self,
hash: &Hash,
)
| 438 | |
| 439 | impl ClosureChangeSource for StoreClosureSource<'_> { |
| 440 | fn get( |
| 441 | &mut self, |
| 442 | hash: &Hash, |
| 443 | ) -> Result<Option<Change>, crate::git_binding::BindingClosureError> { |
| 444 | if !self.repo.has_change(hash) { |
| 445 | return Ok(None); |
| 446 | } |
| 447 | self.repo.load_change(hash).map(Some).map_err(|error| { |
| 448 | crate::git_binding::BindingClosureError::Quarantine { |
| 449 | hash: hash.to_base32(), |
| 450 | source: crate::git_binding::BindingPackError::ChangeDecode { |
| 451 | key: hash.to_base32(), |
| 452 | reason: error.to_string(), |
| 453 | }, |
| 454 | } |
| 455 | }) |
| 456 | } |
| 457 | } |
| 458 | |
| 459 | #[cfg(test)] |
nothing calls this directly
no test coverage detected