diff --git a/apps/silo/src/apps/github/workers/github/event-handlers/issue.handler.ts b/apps/silo/src/apps/github/workers/github/event-handlers/issue.handler.ts index 665719ccab..ff57bf2e23 100644 --- a/apps/silo/src/apps/github/workers/github/event-handlers/issue.handler.ts +++ b/apps/silo/src/apps/github/workers/github/event-handlers/issue.handler.ts @@ -130,17 +130,8 @@ export const syncIssueWithPlane = async (store: Store, data: GithubIssueDedupPay issue ? true : false ); - const states = (await planeClient.state.list(entityConnection.workspace_slug, entityConnection.project_id ?? "")) - .results; const users = await planeClient.users.list(entityConnection.workspace_slug, entityConnection.project_id ?? ""); - if (planeIssue.state) { - const state = states.find((s) => s.name === planeIssue.state); - if (state) { - planeIssue.state = state.id; - } - } - if (planeIssue.labels) { const labels = (await planeClient.label.list(entityConnection.workspace_slug, entityConnection.project_id ?? "")) .results; diff --git a/packages/etl/src/github/etl/transform-to-plane.ts b/packages/etl/src/github/etl/transform-to-plane.ts index 6c4a87af61..58fcf9a105 100644 --- a/packages/etl/src/github/etl/transform-to-plane.ts +++ b/packages/etl/src/github/etl/transform-to-plane.ts @@ -83,8 +83,8 @@ export const transformGitHubIssue = async ( let targetState: string | undefined = undefined; if (issue.state) { const states = (await planeClient.state.list(workspaceSlug, projectId)).results; - const backlogState = states.find((state) => state.name.toLowerCase() === "backlog"); - const doneState = states.find((state) => state.name.toLowerCase() === "done"); + const backlogState = states.find((state) => state.group === "backlog"); + const doneState = states.find((state) => state.group === "completed"); if (issue.state === "open") { targetState = backlogState?.id; } else if (issue.state === "closed") {