Fix $file visibility in Product and Category