Return image with given tag

def image_by_tag(self, tag):
        """
        Return image with given tag
        """
        if not tag:
            return None

        return next((image for image in self.images() if tag
                     in image['RepoTags']), None)