Skip to content

Commit 4749dcc

Browse files
committed
Fixed empty PR branch custom value
1 parent 2408966 commit 4749dcc

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Diff for: src/main/java/com/gradle/CustomBuildScanEnhancements.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -248,7 +248,7 @@ private void execute() {
248248
addCustomValueAndSearchLink(buildScan, "CI workflow", value));
249249
envVariable("GITHUB_RUN_ID").ifPresent(value ->
250250
addCustomValueAndSearchLink(buildScan, "CI run", value));
251-
envVariable("GITHUB_HEAD_REF").ifPresent(value ->
251+
envVariable("GITHUB_HEAD_REF").filter(value -> !value.isEmpty()).ifPresent(value ->
252252
buildScan.value("PR branch", value));
253253
}
254254

0 commit comments

Comments
 (0)