Kostyl-fix for old Kazeev code