Refactoring... added in logic layer.