def get_all_images_count(self):
self_imgs = self.image_set.count()<EOL>update_ids = self.update_set.values_list('<STR_LIT:id>', flat=True)<EOL>u_images = UpdateImage.objects.filter(update__id__in=update_ids).count()<EOL>count = self_imgs + u_images<EOL>return count<EOL>
Gets count of all images from both event and updates.