Skip to content
This repository has been archived by the owner on Apr 9, 2021. It is now read-only.

Commit

Permalink
Exempt FBH mods from FBH command restriction
Browse files Browse the repository at this point in the history
  • Loading branch information
Nanabell committed Feb 22, 2019
1 parent a13aba9 commit 76c91d0
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -40,8 +40,8 @@ import fredboat.sentinel.RawUser
import fredboat.shared.constant.BotConstants
import fredboat.util.DiscordUtil
import fredboat.util.TextUtils
import kotlinx.coroutines.reactive.awaitSingle
import kotlinx.coroutines.delay
import kotlinx.coroutines.reactive.awaitSingle
import org.springframework.beans.factory.annotation.Qualifier
import org.springframework.stereotype.Component
import java.util.*
Expand Down Expand Up @@ -83,6 +83,7 @@ class CommandManager(private val patronageChecker: PatronageChecker, private val
if (guild.id == BotConstants.FREDBOAT_HANGOUT_ID && DiscordUtil.isOfficialBot(selfUser.id)) {
if (channel.id != 174821093633294338L // #spam_and_music
&& channel.id != 217526705298866177L // #staff
&& invoker.roles.any { it.id == BotConstants.FBH_MODERATOR_ROLE_ID }
&& !PermsUtil.checkPerms(PermissionLevel.ADMIN, invoker)) {
context.deleteMessage()
val response = context.replyWithNameMono(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,7 @@ public class BotConstants {
public static final long CUTTING_EDGE_BOT_ID = 341924447139135488L;

public static final long FREDBOAT_HANGOUT_ID = 174820236481134592L;
public static final long FBH_MODERATOR_ROLE_ID = 242377373947920384L;
public static final Color FREDBOAT_COLOR = new Color(28, 191, 226); //#1CBFE2

public static final String FREDBOAT_URL = "https://fredboat.com";
Expand Down

0 comments on commit 76c91d0

Please sign in to comment.