Dynamically delete tags if they aren't linked to any photos