Do not try to match empty query
Add associated test
Merge pull request #12 from Neamar/empty-query

Do not try to match empty query