diff options
| author | 2019-03-30 10:37:59 -0400 | |
|---|---|---|
| committer | 2019-03-30 10:37:59 -0400 | |
| commit | 5fe5b7c688e19e533fe34d98b8c754bc67a58beb (patch) | |
| tree | 16c2946f97f85facf6b994b3c48099d369ee7f5a /bot/seasons/evergreen/fun.py | |
| parent | Merge pull request #163 from python-discord/easter_announce (diff) | |
| parent | Blank line required between summary line and description. (diff) | |
Merge pull request #146 from python-discord/flake8-docstring
Implement flake8-docstrings
Diffstat (limited to '')
| -rw-r--r-- | bot/seasons/evergreen/fun.py | 14 | 
1 files changed, 6 insertions, 8 deletions
diff --git a/bot/seasons/evergreen/fun.py b/bot/seasons/evergreen/fun.py index 9ef47331..286d8462 100644 --- a/bot/seasons/evergreen/fun.py +++ b/bot/seasons/evergreen/fun.py @@ -8,19 +8,16 @@ from bot.constants import Emojis  log = logging.getLogger(__name__) -class Fun(commands.Cog): -    """ -    A collection of general commands for fun. -    """ +class Fun: +    """A collection of general commands for fun."""      def __init__(self, bot):          self.bot = bot      @commands.command()      async def roll(self, ctx, num_rolls: int = 1): -        """ -            Outputs a number of random dice emotes (up to 6) -        """ +        """Outputs a number of random dice emotes (up to 6).""" +          output = ""          if num_rolls > 6:              num_rolls = 6 @@ -32,7 +29,8 @@ class Fun(commands.Cog):          await ctx.send(output) -# Required in order to load the cog, use the class name in the add_cog function.  def setup(bot): +    """Fun Cog load.""" +      bot.add_cog(Fun(bot))      log.info("Fun cog loaded")  |