Report errors to server

This commit is contained in:
jude
2023-06-20 13:13:26 +01:00
parent 9d8622f418
commit 1519474f93
10 changed files with 92 additions and 18 deletions

View File

@ -2,11 +2,7 @@ use std::collections::HashMap;
use chrono::{naive::NaiveDateTime, Utc};
use rand::{rngs::OsRng, seq::IteratorRandom};
use rocket::{
http::CookieJar,
response::Redirect,
serde::json::{json, Value as JsonValue},
};
use rocket::{http::CookieJar, response::Redirect, serde::json::json};
use rocket_dyn_templates::Template;
use serde::{Deserialize, Deserializer, Serialize};
use serenity::{
@ -24,6 +20,7 @@ use crate::{
MAX_EMBED_FIELD_VALUE_LENGTH, MAX_EMBED_FOOTER_LENGTH, MAX_EMBED_TITLE_LENGTH,
MAX_URL_LENGTH, MAX_USERNAME_LENGTH, MIN_INTERVAL,
},
routes::JsonResult,
Database, Error,
};
@ -31,7 +28,6 @@ pub mod export;
pub mod guild;
pub mod user;
pub type JsonResult = Result<JsonValue, JsonValue>;
type Unset<T> = Option<T>;
fn name_default() -> String {