Refactoring to remove unneeded imports and dependencies.