Fixing DM issues with nsfw

This commit is contained in:
Adriene Hutchins 2020-03-03 01:26:58 -05:00
parent 13c57dff51
commit a17fd00de5
1 changed files with 2 additions and 1 deletions

View File

@ -306,7 +306,8 @@ class Search(commands.Cog):
term = ctx.message.content.replace(ctx.prefix, '', 1)
term = term.lstrip(' ')
# Does search
msg = await self._search_logic(term, ctx.channel.is_nsfw())
is_nsfw = ctx.channel.is_nsfw() if hasattr(ctx.channel, 'is_nsfw') else False
msg = await self._search_logic(term, is_nsfw)
# Logging
await self.info(