Refactored main component code