Skip to content

Commit ac90f4b

Browse files
author
Luke Wesley-Holley
authored
fix: automatic progressive releases (#5219)
* fix: automatic progressive releases * Add comment
1 parent a887a7e commit ac90f4b

1 file changed

Lines changed: 13 additions & 0 deletions

File tree

static/js/publisher/pages/Releases/releasesState.js

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -50,6 +50,19 @@ function initReleasesData(revisionsMap, releases, channelMap) {
5050
if (currentChannel) {
5151
release.progressive["current-percentage"] =
5252
currentChannel.progressive["current-percentage"];
53+
// if the current channel has a different percentage
54+
// than the release, we need to update the release
55+
// to match the current channel's percentage
56+
// If the current channel is null, this means that
57+
// an automatic release was completed
58+
// and we need to set the percentage to 100
59+
if (
60+
currentChannel.progressive.percentage !==
61+
release.progressive.percentage
62+
) {
63+
release.progressive.percentage =
64+
currentChannel.progressive.percentage || 100;
65+
}
5366
}
5467
}
5568
}

0 commit comments

Comments
 (0)