forked from jmug/stoatchat
Start moving to Rocket 0.5.0
This commit is contained in:
@@ -2,9 +2,9 @@ use crate::database::*;
|
||||
use crate::util::result::Result;
|
||||
|
||||
use mongodb::bson::doc;
|
||||
use rocket_contrib::json::JsonValue;
|
||||
use rocket::serde::json::Value;
|
||||
|
||||
#[get("/unreads")]
|
||||
pub async fn req(user: User) -> Result<JsonValue> {
|
||||
pub async fn req(user: User) -> Result<Value> {
|
||||
Ok(json!(User::fetch_unreads(&user.id).await?))
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user