Skip to content

Commit

Permalink
fix: update existing repos
Browse files Browse the repository at this point in the history
  • Loading branch information
anbraten committed Apr 19, 2024
1 parent 4c320fe commit d921672
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions server/api/forges/[forge_id]/repos/add.post.ts
Original file line number Diff line number Diff line change
Expand Up @@ -27,11 +27,11 @@ export default defineEventHandler(async (event) => {
const repo = await db
.insert(repoSchema)
.values({
remoteId: forgeRepo.id.toString(),
forgeId: forgeRepo.forgeId,
name: forgeRepo.name,
cloneUrl: forgeRepo.cloneUrl,
remoteId: forgeRepo.id.toString(),
url: forgeRepo.url,
forgeId: forgeRepo.forgeId,
defaultBranch: forgeRepo.defaultBranch,
avatarUrl: forgeRepo.avatarUrl,
})
Expand All @@ -41,6 +41,8 @@ export default defineEventHandler(async (event) => {
name: forgeRepo.name,
cloneUrl: forgeRepo.cloneUrl,
url: forgeRepo.url,
defaultBranch: forgeRepo.defaultBranch,
avatarUrl: forgeRepo.avatarUrl,
},
})
.returning()
Expand Down

0 comments on commit d921672

Please sign in to comment.