Skip to content

Conversation

@Timmy38
Copy link
Contributor

@Timmy38 Timmy38 commented Dec 23, 2025

No description provided.

@CombodoApplicationsAccount CombodoApplicationsAccount added the internal Work made by Combodo label Dec 23, 2025
@Timmy38 Timmy38 requested a review from odain-cbd December 23, 2025 15:24
$aExtensionsAdded = [];
$aExtensionsRemoved = [];
$aExtensionsNotUninstallable = [];
foreach ($this->oExtensionsMap->GetAllExtensionsWithPreviouslyInstalled() as $oExtension) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

could you extract all changes in a separate function? and cover it with tests?

$this->oWizard->SetParameter('old_addon', true);
}

$aExtensionsAdded = [];
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

the 2 arrays could contain html lines instead of extension codes. afterwhile you could use implode. code would be simpler.

} elseif (!$oExtension->bInstalled && $bSelected) {
$aExtensionsAdded[$oExtension->sCode] = $oExtension->sLabel;
}
if (!$oExtension->CanBeUninstalled()) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

no need to add uninstallable extensions when added. please move this 3 lines above.

}
}

$sExtensionsAdded = '<ul><li>No extension added.</li></ul>';
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this variable is initialized with a useless value when below array count >0.

$sExtensionsAdded .= '</ul>';
}

$sExtensionsRemoved = '<ul><li>No extension removed.</li></ul>';
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

same remark. this variable is initialized with a useless value when below array count >0.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

internal Work made by Combodo

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants