def get_thumbnail_tag(self, image, size=None):
        size = size and (50, 50)
        thumb = self.get_thumbnail(image.path, size)
        url = thumb.url.replace(
            '%s/' % settings.MEDIA_ROOT, settings.MEDIA_URL)
        res = '<a href="%s" target="_blank"><img src="%s" height="%s" /></a>'

        return res % (image.url, url, size[1])
dataset/ETHPy150Open gkmngrgn/radpress/radpress/models.py/ThumbnailModelMixin.get_thumbnail_tag/operator `or` -> `and`