Fixed bugs with filtering algorithm and src tags

Fixes #97