added main function back in