mirror of
https://gitcode.com/gh_mirrors/hy/Hydro.git
synced 2026-10-20 01:38:19 +08:00
ci: fix build [skip-cache]
This commit is contained in:
5 files changed
+9
-6
No files matched your search
@@ -28,7 +28,7 @@
|
||||
"emojis-list": "2.1.0",
|
||||
"fs-extra": "^11.1.1",
|
||||
"graphql": "^16.6.0",
|
||||
"graphql-scalars": "1.22.1",
|
||||
"graphql-scalars": "^1.22.2",
|
||||
"js-yaml": "^4.1.0",
|
||||
"koa": "^2.14.2",
|
||||
"koa-body": "^6.0.1",
|
||||
@@ -60,7 +60,7 @@
|
||||
"@types/adm-zip": "^0.4.34",
|
||||
"@types/fs-extra": "^11.0.1",
|
||||
"@types/js-yaml": "^4.0.5",
|
||||
"@types/koa": "2.13.5",
|
||||
"@types/koa": "^2.13.6",
|
||||
"@types/koa-compress": "^4.0.3",
|
||||
"@types/koa-router": "^7.4.4",
|
||||
"@types/koa-static-cache": "^5.1.1",
|
||||
|
||||
@@ -80,7 +80,7 @@ async function get(ctx: Context) {
|
||||
async function post(ctx: Context) {
|
||||
const {
|
||||
host, port, name, username, password,
|
||||
} = ctx.request.body;
|
||||
} = (ctx.request as any).body;
|
||||
let mongourl = 'mongodb://';
|
||||
if (username) mongourl += `${username}:${password}@`;
|
||||
mongourl += `${host}:${port}/${name}`;
|
||||
|
||||
@@ -2,6 +2,7 @@ import http from 'http';
|
||||
import { tmpdir } from 'os';
|
||||
import { join, resolve } from 'path';
|
||||
import cac from 'cac';
|
||||
import type { Files } from 'formidable';
|
||||
import fs from 'fs-extra';
|
||||
import Koa from 'koa';
|
||||
import Body from 'koa-body';
|
||||
@@ -83,6 +84,7 @@ interface HydroContext {
|
||||
export interface KoaContext extends Koa.Context {
|
||||
HydroContext: HydroContext;
|
||||
handler: any;
|
||||
request: Koa.Request & { body: any, files: Files };
|
||||
session: Record<string, any>;
|
||||
render: (name: string, args: any) => Promise<void>;
|
||||
renderHTML: (name: string, args: any) => Promise<string>;
|
||||
|
||||
@@ -11,7 +11,7 @@ setDiagnosticsOptions({
|
||||
{
|
||||
uri: 'https://hydro.js.org/schema/problemConfig.json',
|
||||
fileMatch: ['hydro://problem/file/config.yaml'],
|
||||
schema: problemConfigSchema,
|
||||
schema: problemConfigSchema as any,
|
||||
},
|
||||
{
|
||||
uri: new URL('/manage/config/schema.json', window.location.href).toString(),
|
||||
|
||||
Reference in new issue
Block a user