The memory bridge's sources off one bundle.
(bundle: &EntryBundle)
| 117 | |
| 118 | /// The memory bridge's sources off one bundle. |
| 119 | fn memory_sources(bundle: &EntryBundle) -> crate::commands::memory::bridge::AttestationSources { |
| 120 | use crate::commands::memory::bridge::{ |
| 121 | AttestationSources, SidecarArtifact, TrackedAttestation, |
| 122 | }; |
| 123 | let attestation = bundle.attestation.as_ref(); |
| 124 | AttestationSources { |
| 125 | tracked: attestation |
| 126 | .and_then(|sources| sources.tracked.as_ref()) |
| 127 | .map(|tracked| TrackedAttestation { |
| 128 | vault_path: tracked.path.clone(), |
| 129 | frontmatter_json: tracked.frontmatter_json.clone(), |
| 130 | content: tracked.content.clone(), |
| 131 | }), |
| 132 | sidecar: attestation |
| 133 | .and_then(|sources| sources.sidecar.as_ref()) |
| 134 | .map(|sidecar| SidecarArtifact { |
| 135 | path: sidecar.path.clone(), |
| 136 | text: sidecar.text.clone(), |
| 137 | }), |
| 138 | } |
| 139 | } |
| 140 | |
| 141 | // --------------------------------------------------------------------------- |
| 142 | // KG wire reconstruction — the domain nodes/edges the JSON renders emit |
no test coverage detected