Refactored helper
Refactored helper