Fix #2199, aka MAGN-4271
Merge pull request #2224 from pboyer/PackageManagerReinstallFix

Fix #2199, aka MAGN-4271