fix fatal error when filter contains closure