Cleaned up main.j