Function
external_position
(
change_hash: Hash,
position: Position<Option<Hash>>,
)
Source from the content-addressed store, hash-verified
| 180 | } |
| 181 | |
| 182 | fn external_position( |
| 183 | change_hash: Hash, |
| 184 | position: Position<Option<Hash>>, |
| 185 | ) -> Option<Position<Hash>> { |
| 186 | let change = match position.change { |
| 187 | None => change_hash, |
| 188 | Some(hash) if hash == Hash::NONE => return None, |
| 189 | Some(hash) => hash, |
| 190 | }; |
| 191 | Some(Position::new(change, position.pos)) |
| 192 | } |
| 193 | |
| 194 | fn current_path_for_position<T: GraphTxnT + TreeTxnT>( |
| 195 | txn: &T, |
Tested by
no test coverage detected