mirror of
https://github.com/soxoj/maigret.git
synced 2026-05-07 06:24:35 +00:00
Removed pattern typing for compatibility
This commit is contained in:
+2
-1
@@ -1,4 +1,5 @@
|
||||
import re
|
||||
import sys
|
||||
|
||||
|
||||
class CaseConverter:
|
||||
@@ -45,7 +46,7 @@ class URLMatcher:
|
||||
return ''
|
||||
|
||||
@classmethod
|
||||
def make_profile_url_regexp(self, url: str, username_regexp: str = '') -> re.Pattern:
|
||||
def make_profile_url_regexp(self, url: str, username_regexp: str = ''):
|
||||
url_main_part = self.extract_main_part(url)
|
||||
for c in self.UNSAFE_SYMBOLS:
|
||||
url_main_part = url_main_part.replace(c, f'\\{c}')
|
||||
|
||||
Reference in New Issue
Block a user