mirror of
https://github.com/yawaflua/Flask-Discord.git
synced 2025-12-10 12:29:30 +02:00
✔ Add low level request method for bot scope resources
This commit is contained in:
@@ -28,6 +28,11 @@ class DiscordModelsBase(metaclass=DiscordModelsMeta):
|
||||
"""
|
||||
return current_app.discord.request(*args, **kwargs)
|
||||
|
||||
@staticmethod
|
||||
def _bot_request(*args, **kwargs):
|
||||
"""A shorthand to :py:func:flask_discord.bot_request`."""
|
||||
return current_app.discord.bot_request(*args, **kwargs)
|
||||
|
||||
@classmethod
|
||||
def fetch_from_api(cls):
|
||||
"""A class method which returns an instance or list of instances of this model by implicitly making an
|
||||
|
||||
Reference in New Issue
Block a user