local: Delete uris in library refresh (fixes #500)

Makes sure we remove uri's that can no longer be found in the tag cache.