fix bug in filtering demo