Applied Kara's recommended changes