'match.group(N)' -> 'match[N]' (#7671)

2.5x faster
This commit is contained in:
Mike Fährmann
2025-06-18 12:59:37 +02:00
parent 475506cc39
commit 41191bb60a
135 changed files with 363 additions and 363 deletions

View File

@@ -67,7 +67,7 @@ class PhilomenaPostExtractor(PhilomenaExtractor):
def __init__(self, match):
PhilomenaExtractor.__init__(self, match)
self.image_id = match.group(match.lastindex)
self.image_id = match[match.lastindex]
def posts(self):
return (self.api.image(self.image_id),)
@@ -116,7 +116,7 @@ class PhilomenaGalleryExtractor(PhilomenaExtractor):
def __init__(self, match):
PhilomenaExtractor.__init__(self, match)
self.gallery_id = match.group(match.lastindex)
self.gallery_id = match[match.lastindex]
def metadata(self):
try: