fix: flush cache works now
count photo downloads
fix: properly count photos, clean up