Compare commits
No commits in common. "6018de870d51e1160be9ac468107b84dae11eadb" and "55f8f29a31ff133a40e15642698f9d8e0e10b4a9" have entirely different histories.
6018de870d
...
55f8f29a31
@ -275,15 +275,13 @@ class Misc(commands.Cog):
|
|||||||
|
|
||||||
@bridge.bridge_command()
|
@bridge.bridge_command()
|
||||||
async def compliment(self, ctx, *,
|
async def compliment(self, ctx, *,
|
||||||
recipient: Optional[str] = None,
|
recipient: Optional[str] = None) -> None:
|
||||||
language: Optional[str] = 'en') -> None:
|
|
||||||
"""
|
"""
|
||||||
Compliment someone (or yourself)
|
Compliment someone (or yourself)
|
||||||
|
|
||||||
Args:
|
Args:
|
||||||
ctx (Any)
|
ctx (Any)
|
||||||
recipient (Optional[str])
|
recipient (Optional[str])
|
||||||
language (Optional[str]) (default: 'en')
|
|
||||||
Returns:
|
Returns:
|
||||||
None
|
None
|
||||||
"""
|
"""
|
||||||
@ -307,7 +305,7 @@ class Misc(commands.Cog):
|
|||||||
else:
|
else:
|
||||||
recipient = discord.utils.escape_mentions(recipient.strip())
|
recipient = discord.utils.escape_mentions(recipient.strip())
|
||||||
with ctx.channel.typing():
|
with ctx.channel.typing():
|
||||||
compliment: str = await self.util.get_compliment(recipient, language)
|
compliment: str = await self.util.get_compliment(recipient)
|
||||||
if compliment:
|
if compliment:
|
||||||
return await ctx.respond(compliment)
|
return await ctx.respond(compliment)
|
||||||
return await ctx.respond("Compliment failed :(")
|
return await ctx.respond("Compliment failed :(")
|
||||||
|
@ -62,7 +62,7 @@ class Util:
|
|||||||
'a chocolate frappuccino', 'a butter pecan coffee', 'a maple pecan latte',
|
'a chocolate frappuccino', 'a butter pecan coffee', 'a maple pecan latte',
|
||||||
'a sea salt caramel mocha', 'a nitro cold brew', 'a pumpkin cold brew',
|
'a sea salt caramel mocha', 'a nitro cold brew', 'a pumpkin cold brew',
|
||||||
'a honey almond flat white', 'a sweet cream cold brew', 'a matcha latte',
|
'a honey almond flat white', 'a sweet cream cold brew', 'a matcha latte',
|
||||||
'a golden latte', 'a turmeric latte', 'a beetroot latte', 'a kopi luwak']
|
'a golden latte', 'a turmeric latte', 'a beetroot latte', 'a Kopi luwak']
|
||||||
self.LAST_5_COFFEES: list = []
|
self.LAST_5_COFFEES: list = []
|
||||||
|
|
||||||
|
|
||||||
@ -207,17 +207,19 @@ class Util:
|
|||||||
|
|
||||||
|
|
||||||
async def get_compliment(self, subject: str,
|
async def get_compliment(self, subject: str,
|
||||||
language: Optional[str] = 'en') -> str:
|
language: Optional[str] = None) -> str:
|
||||||
"""
|
"""
|
||||||
Get Compliment
|
Get Compliment
|
||||||
|
|
||||||
Args:
|
Args:
|
||||||
subject (str)
|
subject (str)
|
||||||
language (Optional[str]) (default: 'en')
|
language (Optional[str])
|
||||||
Returns:
|
Returns:
|
||||||
str
|
str
|
||||||
|
|
||||||
"""
|
"""
|
||||||
|
if not language:
|
||||||
|
return self.COMPLIMENT_GENERATOR.compliment(subject)
|
||||||
return self.COMPLIMENT_GENERATOR.compliment_in_language(subject, language)
|
return self.COMPLIMENT_GENERATOR.compliment_in_language(subject, language)
|
||||||
|
|
||||||
async def get_whisky(self) -> Optional[tuple]:
|
async def get_whisky(self) -> Optional[tuple]:
|
||||||
|
Loading…
x
Reference in New Issue
Block a user