Fixed a problem where the query string was erroneously include in the matching process