Skip to content

Commit 736b01f

Browse files
committed
fix(gitcafe): leave summary line counts out when they cannot be read
1 parent 61c100d commit 736b01f

1 file changed

Lines changed: 7 additions & 1 deletion

File tree

‎packages/source-control-gitcafe/src/server/GitCafePullRequestProvider.ts‎

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -557,8 +557,14 @@ export const make = Effect.gen(function* () {
557557
: yield* lineStats(input, { version: pull.version, headOid: pull.headOid }).pipe(
558558
Effect.orElseSucceed(() => null),
559559
);
560+
// A count that could not be read is absent rather than zero.
561+
const {
562+
additions: _additions,
563+
deletions: _deletions,
564+
...summary
565+
} = Json.toChangeRequest(pull, input);
560566
return {
561-
...Json.toChangeRequest(pull, input),
567+
...summary,
562568
...(changes === null ? {} : changes),
563569
closedAt: pull.closedAt,
564570
mergedAt: pull.mergedAt,

0 commit comments

Comments
 (0)