[DayliMadame] Check permission before sending message to prevent crash
This commit is contained in:
parent
2473d0d0a4
commit
1389a11e46
@ -65,7 +65,7 @@ public class DailyMadame implements NewDayListener{
|
||||
if(guildPreferenceRepository.findByGuildId(guild.getId()).get(0).isDailyMadame()){
|
||||
for(TextChannel iterator : guild.getTextChannels())
|
||||
{
|
||||
if(iterator.isNSFW()){
|
||||
if(iterator.isNSFW() && iterator.canTalk()){
|
||||
chanel = iterator;
|
||||
logger.debug("break: " + chanel.getName());
|
||||
break;
|
||||
|
Loading…
Reference in New Issue
Block a user