eeg_certs/backend/src/online_classroom/users.rs

16 lines
481 B
Rust
Raw Normal View History

use rocket::{http::Status, serde::json::Json};
use super::{ json_result::JsonResult};
// Instead of requesting pages and managing session & cookies manually,
// create a wrapper that:
// - Checks if the session cookie is valid
// - If not, tries to login
// - Makes the request
// - Returns the html string, or an error
#[get("/classroom/users/<full_name>")]
pub async fn get_users(full_name: String) -> (Status, Json<JsonResult<()>>) {
(Status::Ok, JsonResult::ok(()))
}