Change echo to moderator because it can use all the perms that otto has...

This commit is contained in:
Julius de Jeu 2019-06-11 12:21:43 +02:00
parent c5dd44bdbd
commit d97474d028
2 changed files with 4 additions and 6 deletions

View file

@ -1,14 +1,12 @@
package nl.voidcorp.discord.commands.`fun`
import nl.voidcorp.discord.command.Command
import nl.voidcorp.discord.command.CommandGroup
import nl.voidcorp.discord.command.CommandMessage
import nl.voidcorp.discord.command.CommandResult
import nl.voidcorp.discord.command.*
import org.springframework.stereotype.Service
@Service
class Echo : Command("echo", usage = "echo whatever", group = CommandGroup.FUN) {
class Echo : Command("echo", usage = "echo whatever", group = CommandGroup.FUN, commandLevel = CommandLevel.MODERATOR) {
override fun handle(event: CommandMessage): CommandResult {
event.message.delete().queue()
val msg = event.params.drop(1).joinToString(" ")
if (msg.isEmpty())
return CommandResult.PARAMETERS

View file

@ -8,4 +8,4 @@ spring.jpa.generate-ddl=true
spring.jpa.hibernate.ddl-auto=create-drop
spring.jpa.properties.hibernate.jdbc.lob.non_contextual_creation=true
ottobot.version=1.1
ottobot.version=1.2