Skip to content

Commit

Permalink
feat: add core
Browse files Browse the repository at this point in the history
  • Loading branch information
yuki committed Feb 22, 2023
1 parent 024cde6 commit 9e72d2b
Show file tree
Hide file tree
Showing 5 changed files with 108 additions and 76 deletions.
9 changes: 5 additions & 4 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@kokkoro/web",
"version": "0.1.3",
"version": "0.1.4",
"description": "Create web serve for kokkoro.",
"main": "lib/index.js",
"types": "lib/index.d.ts",
Expand Down Expand Up @@ -30,15 +30,16 @@
"uuid": "^9.0.0"
},
"devDependencies": {
"@kokkoro/core": "^2.0.1",
"@kokkoro/database": "^1.0.1",
"@kokkoro/utils": "^0.6.0",
"@types/jsonwebtoken": "^9.0.1",
"@types/koa": "^2.13.5",
"@types/koa-static": "^4.0.2",
"@types/koa__cors": "^3.3.0",
"@types/koa__cors": "^3.3.1",
"@types/koa__router": "^12.0.0",
"@types/uuid": "^9.0.0",
"kokkoro": "^2.0.0-alpha.7"
"@types/uuid": "^9.0.1",
"kokkoro": "^2.0.0-alpha.9"
},
"files": [
"lib"
Expand Down
141 changes: 85 additions & 56 deletions pnpm-lock.yaml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 4 additions & 2 deletions src/controller/bot.controller.ts
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,10 @@ class BotController {
const { uin } = ctx.request.body;
const result = await botService.loginBot(uin);

if (result.data.status) {
ctx.result = result;
if (result.status) {
ctx.result = {
data: result,
};
} else {
ctx.result = {
data: {
Expand Down
Loading

0 comments on commit 9e72d2b

Please sign in to comment.