Refactor the database interactions out of the commands
This commit is contained in:
@@ -20,6 +20,7 @@ use twilight_model::{
|
||||
id::Id
|
||||
};
|
||||
mod commands;
|
||||
mod database;
|
||||
|
||||
#[tokio::main]
|
||||
async fn main() -> anyhow::Result<()> {
|
||||
@@ -74,7 +75,7 @@ fn validate_request(headers: HeaderMap, body: String) -> Result<Interaction, (St
|
||||
return Err((StatusCode::UNAUTHORIZED, "interaction failed signature verification".to_string()))
|
||||
};
|
||||
|
||||
return Ok(interaction);
|
||||
Ok(interaction)
|
||||
}
|
||||
|
||||
async fn post_interaction(
|
||||
|
||||
Reference in New Issue
Block a user