Add asynchronous call to database.

See file 'asynchronous.ts'.
This commit is contained in:
Greg Burri 2022-11-29 15:58:06 +01:00
parent 8a3fef096d
commit d28e765e39
20 changed files with 1323 additions and 1049 deletions

11
backend/src/utils.rs Normal file
View file

@ -0,0 +1,11 @@
use log::error;
pub fn unwrap_print_err<T, E>(r: Result<T, E>) -> T
where
E: std::fmt::Debug
{
if let Err(ref error) = r {
error!("{:?}", error);
}
r.unwrap()
}