Updated main class