Removed some non-existent files from optimize
Removed deleted exception files
Merge pull request #6157 from GrahamCampbell/5.0-compile

[5.0] Fixed The Optimize Command