Remove unneccesary looping. Fixes #7
Search on search type change