Refactoring.
Updated