Updating dependencies
All checks were successful
continuous-integration/drone/push Build is passing

This commit is contained in:
User user
2021-06-02 10:11:52 +02:00
parent 6e561bd30f
commit 97a6b45c92
11 changed files with 6911 additions and 2577 deletions

View File

@ -51,7 +51,7 @@ AdminRoute.get("/settings", async (ctx) => {
AdminRoute.get("/data", async (ctx) => {
const { database } = ctx.query;
let db = DatabaseManager.getDatabase(database);
let db = DatabaseManager.getDatabase(database as string);
if (!db) throw new BadRequestError("Database not found");
let res = await new Promise<string[][]>((yes, no) => {
const stream = db.data.createReadStream({
@ -130,7 +130,7 @@ AdminRoute.get("/database", (ctx) => {
AdminRoute.get("/collections", async (ctx) => {
const { database } = ctx.query;
let db = DatabaseManager.getDatabase(database);
let db = DatabaseManager.getDatabase(database as string);
if (!db) throw new BadRequestError("Database not found");
let res = await new Promise<string[]>((yes, no) => {
@ -156,7 +156,7 @@ AdminRoute.get("/collections", async (ctx) => {
AdminRoute.get("/collections/cleanup", async (ctx) => {
const { database } = ctx.query;
let db = DatabaseManager.getDatabase(database);
let db = DatabaseManager.getDatabase(database as string);
if (!db) throw new BadRequestError("Database not found");
let deleted = await db.runCleanup();
@ -184,7 +184,7 @@ AdminRoute.get(
AdminRoute.get("/database/update", async (ctx) => {
const { database } = ctx.query;
let db = DatabaseManager.getDatabase(database);
let db = DatabaseManager.getDatabase(database as string);
if (!db) throw new NotFoundError("Database not found!");
getForm("/v1/admin/database", "Change Database", {
name: {