Skip to content

Open-source Grok Bot alternative for named AI teammates. Local-first desktop, web, and mobile clients with per-bot tools, instructions, and memory. Independent fork of T3 Code.

refactor(server): simplify error transformation with Effect.mapError in GitHubPullRequestCli (#7385)

aoright1896f39a38f6
diff --git a/apps/server/src/pullRequest/GitHubPullRequestCli.ts b/apps/server/src/pullRequest/GitHubPullRequestCli.ts
index 6272737d4..2084a50d0 100644
--- a/apps/server/src/pullRequest/GitHubPullRequestCli.ts
+++ b/apps/server/src/pullRequest/GitHubPullRequestCli.ts
@@ -1451,8 +1451,7 @@ export const make = Effect.gen(function* () {
// the page. Narrowed to a command that ran and was refused: a missing `gh` or a
// signed-out one fails the same way for every request.
Effect.catchTags({
- GitHubCliCommandError: (error) =>
- filesPage(1).pipe(Effect.catch(() => Effect.fail(error))),
+ GitHubCliCommandError: (error) => filesPage(1).pipe(Effect.mapError(() => error)),
}),
);
},