mirror of
https://gitlab.com/comunic/comunicapiv3
synced 2025-09-25 14:19:45 +00:00
Notifications are pushed asynchronously
This commit is contained in:
@@ -37,7 +37,7 @@ pub async fn configure(r: &mut HttpRequestHandler) -> RequestResult {
|
||||
return r.bad_request("Independent service is unavailable!".to_string());
|
||||
}
|
||||
|
||||
let token = independent_push_notifications_service_helper::create_token()?;
|
||||
let token = independent_push_notifications_service_helper::create_token().await?;
|
||||
|
||||
PushNotificationToken::INDEPENDENT(token)
|
||||
}
|
||||
@@ -47,7 +47,7 @@ pub async fn configure(r: &mut HttpRequestHandler) -> RequestResult {
|
||||
}
|
||||
};
|
||||
|
||||
account_helper::set_push_notification_token(r.user_access_token().unwrap(), status)?;
|
||||
account_helper::set_push_notification_token(r.user_access_token().unwrap(), status).await?;
|
||||
|
||||
r.ok()
|
||||
}
|
Reference in New Issue
Block a user