From dfca7f1340d727f377614b3140b34ceddf521799 Mon Sep 17 00:00:00 2001 From: syuilo Date: Sun, 15 Jul 2018 19:38:06 +0900 Subject: [PATCH] Fix bug --- src/server/web/docs.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/server/web/docs.ts b/src/server/web/docs.ts index 1439ae688..2e8ba4eb8 100644 --- a/src/server/web/docs.ts +++ b/src/server/web/docs.ts @@ -192,7 +192,7 @@ router.get('/*/api/entities/*', async ctx => { const lang = ctx.params[0]; const entity = ctx.params[1]; - const x = yaml.safeLoad(fs.readFileSync(path.resolve('./src/docs/api/entities/' + entity + '.yaml'), 'utf-8')) as any; + const x = yaml.safeLoad(fs.readFileSync(path.resolve(__dirname + '/../../../src/docs/api/entities/' + entity + '.yaml'), 'utf-8')) as any; await ctx.render('../../../../src/docs/api/entities/view', Object.assign(await genVars(lang), { name: x.name,