autocommit 2022-03-30 18:10:37 CEST
This commit is contained in:
parent
c4854c4d7d
commit
a8136ed88c
17 changed files with 189 additions and 81 deletions
|
|
@ -17,11 +17,14 @@ macro_rules! config {
|
|||
|
||||
macro_rules! get {
|
||||
() => {{
|
||||
get!(())
|
||||
}};
|
||||
($def:expr) => {{
|
||||
#[allow(unused_unsafe)]
|
||||
let client = unsafe {
|
||||
let client = crate::_private::client::CLIENT.with(|client| client.get());
|
||||
if client.is_null() {
|
||||
return;
|
||||
return $def;
|
||||
}
|
||||
&*client
|
||||
};
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue