mirror of https://gitlab.com/bashrc2/epicyon
Check in lower case
parent
b45d034332
commit
02b53231b9
|
@ -459,7 +459,8 @@ class PubServer(BaseHTTPRequestHandler):
|
|||
agentDomain = None
|
||||
if self.headers.get('User-Agent'):
|
||||
agentStr = self.headers['User-Agent']
|
||||
if 'bot/' in agentStr or 'bot-' in agentStr.lower():
|
||||
agentStrLower = agentStr.lower()
|
||||
if 'bot/' in agentStrLower or 'bot-' in agentStrLower:
|
||||
print('Crawler: ' + agentStr)
|
||||
return True
|
||||
agentDomain = userAgentDomain(agentStr, self.server.debug)
|
||||
|
|
Loading…
Reference in New Issue