mirror of
https://github.com/Unleash/unleash.git
synced 2025-10-27 11:02:16 +01:00
fix: param names
This commit is contained in:
parent
19b04e8223
commit
bc13e919a8
@ -134,28 +134,34 @@ export const ReleasePlan = ({
|
|||||||
const getPendingProgressionChange = (sourceMilestoneId: string) => {
|
const getPendingProgressionChange = (sourceMilestoneId: string) => {
|
||||||
if (!pendingChangeRequests) return null;
|
if (!pendingChangeRequests) return null;
|
||||||
|
|
||||||
for (const cr of pendingChangeRequests) {
|
for (const changeRequest of pendingChangeRequests) {
|
||||||
if (cr.environment !== environment) continue;
|
if (changeRequest.environment !== environment) continue;
|
||||||
|
|
||||||
const feature = cr.features.find((f) => f.name === featureName);
|
const featureInChangeRequest = changeRequest.features.find(
|
||||||
if (!feature) continue;
|
(featureItem) => featureItem.name === featureName,
|
||||||
|
);
|
||||||
|
if (!featureInChangeRequest) continue;
|
||||||
|
|
||||||
// Look for update or delete progression changes
|
// Look for update or delete progression changes
|
||||||
const change = feature.changes.find(
|
const progressionChange = featureInChangeRequest.changes.find(
|
||||||
(c: any) =>
|
(change: any) =>
|
||||||
(c.action === 'updateMilestoneProgression' &&
|
(change.action === 'updateMilestoneProgression' &&
|
||||||
(c.payload.sourceMilestoneId === sourceMilestoneId ||
|
(change.payload.sourceMilestoneId ===
|
||||||
c.payload.sourceMilestone === sourceMilestoneId)) ||
|
sourceMilestoneId ||
|
||||||
(c.action === 'deleteMilestoneProgression' &&
|
change.payload.sourceMilestone ===
|
||||||
(c.payload.sourceMilestoneId === sourceMilestoneId ||
|
sourceMilestoneId)) ||
|
||||||
c.payload.sourceMilestone === sourceMilestoneId)),
|
(change.action === 'deleteMilestoneProgression' &&
|
||||||
|
(change.payload.sourceMilestoneId ===
|
||||||
|
sourceMilestoneId ||
|
||||||
|
change.payload.sourceMilestone ===
|
||||||
|
sourceMilestoneId)),
|
||||||
);
|
);
|
||||||
|
|
||||||
if (change) {
|
if (progressionChange) {
|
||||||
return {
|
return {
|
||||||
action: change.action,
|
action: progressionChange.action,
|
||||||
payload: change.payload,
|
payload: progressionChange.payload,
|
||||||
changeRequestId: cr.id,
|
changeRequestId: changeRequest.id,
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user