Refactored and removed magic constants