src/config.rs

a67ad42e15d27546a73bef80a1049031245f6eb0
weechat-matrix-rs/src/config.rs history · blame · raw

14 lines · 309 bytes

 1use crate::PLUGIN_NAME;
 2use weechat::Weechat;
 3
 4pub struct Config(weechat::config::Config);
 5
 6impl Config {
 7    pub fn new(weechat: &Weechat) -> Config {
 8        let config = weechat
 9            .config_new(PLUGIN_NAME, |_, _| {})
10            .expect("Can't create new config");
11
12        Config(config)
13    }
14}