Added watchlist paths for Gitea and some minor typescript fixes.

This commit is contained in:
Jason Parks
2025-03-19 16:48:51 -06:00
parent 997e755b6f
commit 56d8defebe
11 changed files with 814 additions and 690 deletions

View File

@@ -511,6 +511,7 @@ export const apiSaveGiteaProvider = createSchema
giteaId: true,
giteaProjectId: true,
giteaPathNamespace: true,
watchPaths: true,
})
.required();

View File

@@ -23,7 +23,7 @@ export const createGitea = async (
name: input.name,
})
.returning()
.then((response: typeof gitProvider.$inferSelect[]) => response[0]);
.then((response: (typeof gitProvider.$inferSelect)[]) => response[0]);
if (!newGitProvider) {
throw new TRPCError({
@@ -39,7 +39,7 @@ export const createGitea = async (
gitProviderId: newGitProvider?.gitProviderId,
})
.returning()
.then((response: typeof gitea.$inferSelect[]) => response[0]);
.then((response: (typeof gitea.$inferSelect)[]) => response[0]);
});
};
@@ -96,4 +96,4 @@ export const updateGitea = async (giteaId: string, input: Partial<Gitea>) => {
console.error("Error updating Gitea provider:", error);
throw error;
}
};
};