MCPcopy Create free account
hub / github.com/Recordscript/recordscript / get_id

Method get_id

libs/hbb_common/src/config.rs:886–895  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

884 }
885
886 pub fn get_id() -> String {
887 let mut id = CONFIG.read().unwrap().id.clone();
888 if id.is_empty() {
889 if let Some(tmp) = Config::get_auto_id() {
890 id = tmp;
891 Config::set_id(&id);
892 }
893 }
894 id
895 }
896
897 pub fn get_id_or(b: String) -> String {
898 let a = CONFIG.read().unwrap().id.clone();

Callers

nothing calls this directly

Calls 3

is_emptyMethod · 0.80
cloneMethod · 0.45
readMethod · 0.45

Tested by

no test coverage detected