Limit caching only to files.