mirror of
https://github.com/Rapptz/discord.py.git
synced 2025-11-25 02:01:28 +00:00
Most data classes now support hashing.
This commit is contained in:
@@ -29,9 +29,9 @@ from .role import Role
|
||||
from .member import Member
|
||||
from .channel import Channel
|
||||
from .enums import ServerRegion, Status
|
||||
from .mixins import EqualityComparable
|
||||
from .mixins import Hashable
|
||||
|
||||
class Server(EqualityComparable):
|
||||
class Server(Hashable):
|
||||
"""Represents a Discord server.
|
||||
|
||||
Supported Operations:
|
||||
@@ -43,6 +43,8 @@ class Server(EqualityComparable):
|
||||
+-----------+--------------------------------------+
|
||||
| x != y | Checks if two servers are not equal. |
|
||||
+-----------+--------------------------------------+
|
||||
| hash(x) | Returns the server's hash. |
|
||||
+-----------+--------------------------------------+
|
||||
| str(x) | Returns the server's name. |
|
||||
+-----------+--------------------------------------+
|
||||
|
||||
|
||||
Reference in New Issue
Block a user