Fix matching of magnet uri to caches