whole dataset nuri

refactor
Niko PLP 3 days ago
parent dbb4e3d7ce
commit 86935837cd
  1. 23
      engine/verifier/src/orm/utils.rs

@ -53,15 +53,20 @@ pub fn group_by_subject_for_shape<'a>(
pub fn nuri_to_string(nuri: &NuriV0) -> String { pub fn nuri_to_string(nuri: &NuriV0) -> String {
// Get repo_id and overlay_id from the nuri // Get repo_id and overlay_id from the nuri
let repo_id = nuri.target.repo_id(); match nuri.target {
let overlay_id = if let Some(overlay_link) = &nuri.overlay { NuriTargetV0::UserSite => "did:ng:i".to_string(),
overlay_link.clone().try_into().unwrap() _ => {
} else { let repo_id = nuri.target.repo_id();
// Default overlay for the repo let overlay_id = if let Some(overlay_link) = &nuri.overlay {
OverlayId::outer(repo_id) overlay_link.clone().try_into().unwrap()
}; } else {
let graph_name = NuriV0::repo_graph_name(repo_id, &overlay_id); // Default overlay for the repo
graph_name OverlayId::outer(repo_id)
};
let graph_name = NuriV0::repo_graph_name(repo_id, &overlay_id);
graph_name
}
}
} }
pub fn escape_json_pointer(path_segment: &String) -> String { pub fn escape_json_pointer(path_segment: &String) -> String {

Loading…
Cancel
Save