remove logic from main method