most mentioned for not member specific
This commit is contained in:
@@ -50,17 +50,19 @@ class Presence:
|
|||||||
f"- **was mentioned**: {plural(mention_sum, 'time')} ({percent(mention_sum/self.mention_count)} of server's)",
|
f"- **was mentioned**: {plural(mention_sum, 'time')} ({percent(mention_sum/self.mention_count)} of server's)",
|
||||||
f"- **mostly mentioned by**: {mention(top_mention)} ({plural(self.mentions[top_mention], 'time')}, {percent(self.mentions[top_mention]/mention_sum)})",
|
f"- **mostly mentioned by**: {mention(top_mention)} ({plural(self.mentions[top_mention], 'time')}, {percent(self.mentions[top_mention]/mention_sum)})",
|
||||||
]
|
]
|
||||||
else:
|
if len(self.mention_others) > 0:
|
||||||
ret += ["- **was mentioned**: 0 times"]
|
top_mention = top_key(self.mention_others)
|
||||||
if len(self.mention_others) > 0:
|
mention_sum = sum(self.mention_others.values())
|
||||||
top_mention = top_key(self.mention_others)
|
if member_specific:
|
||||||
mention_sum = sum(self.mention_others.values())
|
|
||||||
ret += [
|
ret += [
|
||||||
f"- **mentioned others**: {plural(mention_sum, 'time')} ({percent(mention_sum/self.mention_count)} of server's)",
|
f"- **mentioned others**: {plural(mention_sum, 'time')} ({percent(mention_sum/self.mention_count)} of server's)",
|
||||||
f"- **mostly mentioned**: {mention(top_mention)} ({plural(self.mention_others[top_mention], 'time')}, {percent(self.mention_others[top_mention]/mention_sum)})",
|
f"- **mostly mentioned**: {mention(top_mention)} ({plural(self.mention_others[top_mention], 'time')}, {percent(self.mention_others[top_mention]/mention_sum)})",
|
||||||
]
|
]
|
||||||
else:
|
else:
|
||||||
ret += ["- **was mentioned**: 0 times"]
|
ret += [
|
||||||
|
f"- **mentioned**: {plural(mention_sum, 'time')}",
|
||||||
|
f"- **most mentioned**: {mention(top_mention)} ({plural(self.mention_others[top_mention], 'time')}, {percent(self.mention_others[top_mention]/mention_sum)})",
|
||||||
|
]
|
||||||
|
|
||||||
if len(self.reactions) > 0:
|
if len(self.reactions) > 0:
|
||||||
total_used = sum(self.reactions.values())
|
total_used = sum(self.reactions.values())
|
||||||
@@ -73,6 +75,4 @@ class Presence:
|
|||||||
ret[
|
ret[
|
||||||
-2
|
-2
|
||||||
] += f" ({percent(total_used/self.used_reaction_total)} of server's)"
|
] += f" ({percent(total_used/self.used_reaction_total)} of server's)"
|
||||||
else:
|
|
||||||
ret += ["- **reactions**: 0 times"]
|
|
||||||
return ret
|
return ret
|
||||||
|
|||||||
Reference in New Issue
Block a user