code cleanup

#3504