Fixes double search, closes #370

Haven't tested it but I can't see any problems.