mirror of
https://github.com/Cog-Creators/Red-DiscordBot.git
synced 2025-11-06 11:18:54 -05:00
[V3 Launcher] Fix error when removing Mongo instance (#1710)
* [V3 Launcher] Fix error when removing Mongo instance Fixes #1573 * Fix issue causing style check to fail * Remove unneeded whitespace
This commit is contained in:
parent
54975eb812
commit
3337a9cbab
@ -4,7 +4,6 @@ import argparse
|
|||||||
import asyncio
|
import asyncio
|
||||||
import json
|
import json
|
||||||
import os
|
import os
|
||||||
import shutil
|
|
||||||
import sys
|
import sys
|
||||||
import tarfile
|
import tarfile
|
||||||
from copy import deepcopy
|
from copy import deepcopy
|
||||||
@ -319,8 +318,9 @@ async def create_backup(selected, instance_data):
|
|||||||
|
|
||||||
|
|
||||||
async def remove_instance(selected, instance_data):
|
async def remove_instance(selected, instance_data):
|
||||||
instance_list = load_existing_config()
|
|
||||||
if instance_data["STORAGE_TYPE"] == "MongoDB":
|
if instance_data["STORAGE_TYPE"] == "MongoDB":
|
||||||
|
from redbot.core.drivers.red_mongo import Mongo
|
||||||
|
|
||||||
m = Mongo("Core", **instance_data["STORAGE_DETAILS"])
|
m = Mongo("Core", **instance_data["STORAGE_DETAILS"])
|
||||||
db = m.db
|
db = m.db
|
||||||
collections = await db.collection_names(include_system_collections=False)
|
collections = await db.collection_names(include_system_collections=False)
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user