Simplified code again