Improved filter.
Merge pull request #257 from ironbane/filter2

Improved filter.