fixed a bad regressoin in commit 1b615c46.