MCPcopy Create free account
hub / github.com/Kilo-Org/cloud / codeReviewInsertValues

Function codeReviewInsertValues

apps/web/src/lib/code-reviews/db/code-reviews.ts:188–210  ·  view source on GitHub ↗
(
  params: CreateReviewParams
)

Source from the content-addressed store, hash-verified

186
187function createCodeReviewErrorMetadata(params: CreateReviewParams) {
188 return {
189 owner: params.owner,
190 platformIntegrationId: params.platformIntegrationId,
191 repoFullName: params.repoFullName,
192 prNumber: params.prNumber,
193 prUrl: params.prUrl,
194 headSha: params.headSha,
195 platform: params.platform,
196 platformProjectId: params.platformProjectId,
197 manualConfig: params.manualConfig
198 ? {
199 outputMode: params.manualConfig.outputMode,
200 hasInstructions: params.manualConfig.instructions !== null,
201 modelSlug: params.manualConfig.agentConfig.model_slug,
202 thinkingEffort: params.manualConfig.agentConfig.thinking_effort ?? null,
203 }
204 : null,
205 };
206}
207
208function codeReviewInsertValues(
209 params: CreateReviewParams
210): typeof cloud_agent_code_reviews.$inferInsert {
211 return {
212 owned_by_organization_id: params.owner.type === 'org' ? params.owner.id : null,
213 owned_by_user_id: params.owner.type === 'user' ? params.owner.id : null,

Callers 2

createCodeReviewFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected