Fix searching by path when on virtualhosts