remove unnecessary code from prev. See #2288
#2295