Support block function as condition