Skip to content

Commit 847d595

Browse files
author
Aaron Suarez
authored
Merge pull request #227 from LivingInSyn/patch-1
Fix off by 1 in /roll
2 parents d09ca5d + 3157002 commit 847d595

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

pybot/endpoints/slack/commands.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -150,7 +150,7 @@ async def slash_roll(command: Command, app: SirBot):
150150
)
151151
return await slack.query(methods.CHAT_POST_EPHEMERAL, response)
152152

153-
dice = [random.randint(1, typedice + 1) for _ in range(numdice)]
153+
dice = [random.randint(1, typedice) for _ in range(numdice)]
154154
message = f"<@{slack_id}> Rolled {numdice} D{typedice}: {dice}"
155155
response = dict(channel=channel_id, text=message)
156156
await slack.query(methods.CHAT_POST_MESSAGE, response)

0 commit comments

Comments
 (0)