From 1896f39a38f6fe980ea137fbc402dde8be17b83a Mon Sep 17 00:00:00 2001 From: aoright <102943475+aoright@users.noreply.github.com> Date: Wed, 19 Aug 2026 01:38:55 +0800 Subject: [PATCH] refactor(server): simplify error transformation with Effect.mapError in GitHubPullRequestCli (#7385) Signed-off-by: aoright <102943475+aoright@users.noreply.github.com> --- apps/server/src/pullRequest/GitHubPullRequestCli.ts | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/apps/server/src/pullRequest/GitHubPullRequestCli.ts b/apps/server/src/pullRequest/GitHubPullRequestCli.ts index 6272737d4a82c61249b1dc5414432b58bc576c6d..2084a50d02061e38d4d5712223b160405e22c496 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)), }), ); }, -- 2.54.0