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

Method resolve_body

atomic-cli/src/commands/intent/update.rs:57–70  ·  view source on GitHub ↗
(&self)

Source from the content-addressed store, hash-verified

55
56impl IntentUpdate {
57 fn resolve_body(&self) -> CliResult<Option<String>> {
58 if let Some(ref body) = self.body {
59 return Ok(Some(body.clone()));
60 }
61 if self.body_stdin {
62 use std::io::Read;
63 let mut content = String::new();
64 std::io::stdin()
65 .read_to_string(&mut content)
66 .map_err(CliError::Io)?;
67 return Ok(Some(content));
68 }
69 Ok(None)
70 }
71}
72
73impl Command for IntentUpdate {

Callers 1

runMethod · 0.45

Calls 1

cloneMethod · 0.45

Tested by

no test coverage detected