Rename Server to Guild everywhere.

This commit is contained in:
Rapptz
2016-10-17 18:25:23 -04:00
parent f33eaa4a61
commit d1d54a468a
24 changed files with 632 additions and 630 deletions

View File

@ -31,7 +31,7 @@ __all__ = ['BucketType', 'Cooldown', 'CooldownMapping']
class BucketType(enum.Enum):
default = 0
user = 1
server = 2
guild = 2
channel = 3
class Cooldown:
@ -97,8 +97,8 @@ class CooldownMapping:
bucket_type = self._cooldown.type
if bucket_type is BucketType.user:
return msg.author.id
elif bucket_type is BucketType.server:
return getattr(msg.server, 'id', msg.author.id)
elif bucket_type is BucketType.guild:
return getattr(msg.guild, 'id', msg.author.id)
elif bucket_type is BucketType.channel:
return msg.channel.id