MCPcopy Create free account
hub / github.com/chatmail/core / get_raw_config_bool

Method get_raw_config_bool

src/sql.rs:632–637  ·  view source on GitHub ↗

Returns boolean configuration value for the given key.

(&self, key: &str)

Source from the content-addressed store, hash-verified

630
631 /// Returns boolean configuration value for the given key.
632 pub async fn get_raw_config_bool(&self, key: &str) -> Result<bool> {
633 // Not the most obvious way to encode bool as string, but it is matter
634 // of backward compatibility.
635 let res = self.get_raw_config_int(key).await?;
636 Ok(res.unwrap_or_default() > 0)
637 }
638
639 /// Sets configuration for the given key to boolean value.
640 pub async fn set_raw_config_bool(&self, key: &str, value: bool) -> Result<()> {

Callers 1

update_device_chatsMethod · 0.80

Calls 1

get_raw_config_intMethod · 0.80

Tested by

no test coverage detected