Fixed some regressions from the previous change.