diff options
| author | syuilo <syuilotan@yahoo.co.jp> | 2019-04-10 15:04:27 +0900 |
|---|---|---|
| committer | syuilo <syuilotan@yahoo.co.jp> | 2019-04-10 15:04:27 +0900 |
| commit | 626cfb61ac3940bee7a3acf1b1c5c4cae4ae410c (patch) | |
| tree | 23b89c000b1b169c36cffc7a345a2fc1ebe33347 /src/server/api/service/github.ts | |
| parent | Delete get-user-summary.ts (diff) | |
| download | sharkey-626cfb61ac3940bee7a3acf1b1c5c4cae4ae410c.tar.gz sharkey-626cfb61ac3940bee7a3acf1b1c5c4cae4ae410c.tar.bz2 sharkey-626cfb61ac3940bee7a3acf1b1c5c4cae4ae410c.zip | |
テーブル分割
Diffstat (limited to 'src/server/api/service/github.ts')
| -rw-r--r-- | src/server/api/service/github.ts | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/server/api/service/github.ts b/src/server/api/service/github.ts index e59b149d19..580947811b 100644 --- a/src/server/api/service/github.ts +++ b/src/server/api/service/github.ts @@ -8,7 +8,7 @@ import redis from '../../../db/redis'; import * as uuid from 'uuid'; import signin from '../common/signin'; import fetchMeta from '../../../misc/fetch-meta'; -import { Users, UserServiceLinkings } from '../../../models'; +import { Users, UserProfiles } from '../../../models'; import { ILocalUser } from '../../../models/entities/user'; function getUserToken(ctx: Koa.BaseContext) { @@ -45,7 +45,7 @@ router.get('/disconnect/github', async ctx => { token: userToken }); - await UserServiceLinkings.update({ + await UserProfiles.update({ userId: user.id }, { github: false, @@ -191,7 +191,7 @@ router.get('/gh/cb', async ctx => { return; } - const link = await UserServiceLinkings.createQueryBuilder() + const link = await UserProfiles.createQueryBuilder() .where('github @> :github', { github: { id: id, @@ -263,7 +263,7 @@ router.get('/gh/cb', async ctx => { token: userToken }); - await UserServiceLinkings.update({ userId: user.id }, { + await UserProfiles.update({ userId: user.id }, { github: true, githubAccessToken: accessToken, githubId: id, |