Removing unneeded imports.
Slight refactoring for completeness.