Apply formatting
This commit is contained in:
parent
0a72637661
commit
5dae504c02
13
src/main.rs
13
src/main.rs
|
@ -55,7 +55,11 @@ fn main() {
|
||||||
StandardFramework::new()
|
StandardFramework::new()
|
||||||
.configure(|c| {
|
.configure(|c| {
|
||||||
c.with_whitespace(true)
|
c.with_whitespace(true)
|
||||||
.owners(vec![UserId(254310746450690048), UserId(687740609703706630)].into_iter().collect())
|
.owners(
|
||||||
|
vec![UserId(254310746450690048), UserId(687740609703706630)]
|
||||||
|
.into_iter()
|
||||||
|
.collect(),
|
||||||
|
)
|
||||||
.prefixes(vec!["owo ", "OwO "])
|
.prefixes(vec!["owo ", "OwO "])
|
||||||
.no_dm_prefix(true)
|
.no_dm_prefix(true)
|
||||||
.case_insensitivity(true)
|
.case_insensitivity(true)
|
||||||
|
@ -260,7 +264,9 @@ fn embed(ctx: &mut Context, message: &Message, args: Args) -> CommandResult {
|
||||||
m
|
m
|
||||||
});
|
});
|
||||||
|
|
||||||
let _ = message.channel_id.say(&ctx.http, format!("Embed requested by: {}", message.author));
|
let _ = message
|
||||||
|
.channel_id
|
||||||
|
.say(&ctx.http, format!("Embed requested by: {}", message.author));
|
||||||
|
|
||||||
Ok(())
|
Ok(())
|
||||||
}
|
}
|
||||||
|
@ -364,10 +370,9 @@ fn ship(ctx: &mut Context, message: &Message, args: Args) -> CommandResult {
|
||||||
fn headpat(ctx: &mut Context, message: &Message, args: Args) -> CommandResult {
|
fn headpat(ctx: &mut Context, message: &Message, args: Args) -> CommandResult {
|
||||||
let name = match message.mentions.len() {
|
let name = match message.mentions.len() {
|
||||||
0 => args.rest().trim(),
|
0 => args.rest().trim(),
|
||||||
_ => message.mentions[0].name.as_str()
|
_ => message.mentions[0].name.as_str(),
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
if let Err(e) = message.channel_id.send_message(&ctx.http, |m| {
|
if let Err(e) = message.channel_id.send_message(&ctx.http, |m| {
|
||||||
m.embed(|e| {
|
m.embed(|e| {
|
||||||
e.title(format!("Sending headpats to **{}**...", name))
|
e.title(format!("Sending headpats to **{}**...", name))
|
||||||
|
|
Loading…
Reference in New Issue