[Core] Server based prefixes (#492)

Added `[p]set serverprefix`
`Bot.command_prefix` is now a callable that returns the prefixes set for the server. If none are set, it returns the global ones.
This commit is contained in:
Twentysix
2016-12-01 02:30:51 +01:00
committed by GitHub
parent 8b7ba988f4
commit d628bacef5
6 changed files with 127 additions and 62 deletions

View File

@@ -745,8 +745,8 @@ class Audio:
song = await self._guarantee_downloaded(server, url)
except MaximumLength:
log.warning("I can't play URL below because it is too long."
" Use {}audioset maxlength to change this.\n\n"
"{}".format(self.bot.command_prefix[0], url))
" Use [p]audioset maxlength to change this.\n\n"
"{}".format(url))
raise
local = False
else: # Assume local