use super::*;
use internal::establish_connection;

#[command]
#[aliases("ig")]
#[description = "Ignore user"]
#[allowed_roles("Officiers Rishi", "Officiers Ukio")]
#[usage = "<USER>"]
#[example = "@foo"]
pub fn ignore(ctx: &mut Context, msg: &Message, _args: Args) -> CommandResult {
    let conn = establish_connection();

    update_ignore(&conn, msg, true)?;

    msg.reply(ctx, "User successfully ignored.")?;

    Ok(())
}
