Fixed code for 3.18