Added classes to filter and fixed bug