MCPcopy Create free account
hub / github.com/enowdev/enowX-Coder / cancel

Method cancel

src-tauri/src/state.rs:70–76  ·  view source on GitHub ↗

Cancel the token associated with the given key (if any).

(&self, key: &str)

Source from the content-addressed store, hash-verified

68
69 /// Cancel the token associated with the given key (if any).
70 pub fn cancel(&self, key: &str) {
71 if let Ok(mut map) = self.tokens.lock() {
72 if let Some(token) = map.remove(key) {
73 token.cancel();
74 }
75 }
76 }
77
78 /// Remove the token for the given key without cancelling it (cleanup after normal completion).
79 pub fn remove(&self, key: &str) {

Callers 2

cancel_agentFunction · 0.80
cancel_chatFunction · 0.80

Calls 1

removeMethod · 0.80

Tested by

no test coverage detected