Skip to content

Commit

Permalink
Added strikethrough, bolden and italicize to discord string methods
Browse files Browse the repository at this point in the history
  • Loading branch information
metagn committed Jan 17, 2016
1 parent 2129ede commit 4910e19
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/ml/hlaaftana/discordg/util/RandomUtil.groovy
Original file line number Diff line number Diff line change
Expand Up @@ -210,9 +210,12 @@ class RandomUtil {

}
String.metaClass.bold = { return "**$delegate**" }
String.metaClass.bolden = { return "**$delegate**" }
String.metaClass.italic = { return "*$delegate*" }
String.metaClass.italicize = { return "*$delegate*" }
String.metaClass.underline = { return "__${delegate}__" }
String.metaClass.code = { return "`$delegate`" }
String.metaClass.block = { String language="" -> return "```$language\n$delegate```" }
String.metaClass.strikethrough = { return "~~$delegate~~" }
}
}

0 comments on commit 4910e19

Please sign in to comment.