Fixes modules being installed after an error
Removed the call to uninstall
Updated code style
Merge pull request #2190 from firesale/2.2/develop

Fixes modules being installed after an error