Files
ew/src/router/debug.rs
T

13 lines
317 B
Rust

use json::{JsonValue, object};
use actix_web::{HttpRequest};
use crate::encryption;
pub fn error(_req: HttpRequest, body: String) -> Option<JsonValue> {
let body = json::parse(&encryption::decrypt_packet(&body).unwrap()).unwrap();
println!("client error: {}", body["code"]);
Some(object!{})
}