MCPcopy Create free account
hub / github.com/atomicdotdev/atomic / governed

Function governed

libatomic/src/review/graph.rs:72–88  ·  view source on GitHub ↗
(change: &ChangeInspection, intent: &IntentCriteria)

Source from the content-addressed store, hash-verified

70}
71
72fn governed(change: &ChangeInspection, intent: &IntentCriteria) -> bool {
73 change.intent_context["status"] == "recorded"
74 && change.intent_context["plans"]
75 .as_array()
76 .is_some_and(|plans| {
77 plans.iter().any(|plan| {
78 [
79 plan["plan_id"].as_str(),
80 plan["intent"]["uid"].as_str(),
81 plan["intent"]["id"].as_str(),
82 ]
83 .into_iter()
84 .flatten()
85 .any(|alias| intent.aliases.contains(alias))
86 })
87 })
88}
89
90fn catalog(report: &IncrementalReport) -> Vec<IntentCriteria> {
91 report

Callers 3

catalogFunction · 0.85
buildFunction · 0.85
validate_inputFunction · 0.85

Calls 4

iterMethod · 0.45
into_iterMethod · 0.45
as_strMethod · 0.45
containsMethod · 0.45

Tested by

no test coverage detected