Cleanup

Improving readability
Modularizing attribute-filter.js