mirror of
https://github.com/Cog-Creators/Red-DiscordBot.git
synced 2026-04-21 18:49:17 -04:00
Add basic backcompat for people using Downloader internals (#6713)
This commit is contained in:
@@ -50,6 +50,17 @@ class Downloader(commands.Cog):
|
||||
"""Nothing to delete"""
|
||||
return
|
||||
|
||||
# This is a compatibility shim for people using Downloader internal pre-3.5.25.
|
||||
# It will probably get removed in Red 3.6.
|
||||
@property
|
||||
def _repo_manager(self):
|
||||
return _downloader._repo_manager
|
||||
|
||||
# This is a compatibility shim for people using Downloader internal pre-3.5.25.
|
||||
# It will probably get removed in Red 3.6.
|
||||
async def installed_cogs(self) -> Tuple[InstalledModule, ...]:
|
||||
return await _downloader.installed_cogs()
|
||||
|
||||
@staticmethod
|
||||
async def send_pagified(target: discord.abc.Messageable, content: str) -> None:
|
||||
for page in pagify(content):
|
||||
|
||||
8
redbot/cogs/downloader/repo_manager.py
Normal file
8
redbot/cogs/downloader/repo_manager.py
Normal file
@@ -0,0 +1,8 @@
|
||||
# This is a compatibility shim for people using Downloader internal pre-3.5.25.
|
||||
# It will probably get removed in Red 3.6.
|
||||
|
||||
# import everything from repo_manager module
|
||||
from redbot.core._downloader.repo_manager import *
|
||||
|
||||
# use Repo subclass with `convert()` method instead of Repo from repo_manager module
|
||||
from .converters import Repo
|
||||
Reference in New Issue
Block a user