Added check if a filter function is callable