MCPcopy Create free account
hub / github.com/ChrisFeldmeier/OpenCodeRust / go_back

Method go_back

crates/opencode-tui/src/router.rs:53–62  ·  view source on GitHub ↗
(&mut self)

Source from the content-addressed store, hash-verified

51 }
52
53 pub fn go_back(&mut self) -> bool {
54 if self.history.len() > 1 {
55 self.history.pop();
56 if let Some(prev) = self.history.last() {
57 self.current = prev.clone();
58 return true;
59 }
60 }
61 false
62 }
63
64 pub fn is_home(&self) -> bool {
65 matches!(self.current, Route::Home)

Callers

nothing calls this directly

Calls 1

cloneMethod · 0.45

Tested by

no test coverage detected