mirror of
https://github.com/ai-robots-txt/ai.robots.txt.git
synced 2026-09-23 18:34:17 +02:00
robots.py: agents/agents -> agents
This commit is contained in:
parent
3091ad0a23
commit
bd3ee4702c
1 changed files with 6 additions and 1 deletions
|
|
@ -10,7 +10,12 @@ from pathlib import Path
|
|||
|
||||
def load_robots_json():
|
||||
"""Load the robots.json contents into a dictionary."""
|
||||
return json.loads(Path("./robots.json").read_text(encoding="utf-8"))
|
||||
bots = json.loads(Path("./robots.json").read_text(encoding="utf-8"))
|
||||
for ro in bots:
|
||||
if "description" in ro:
|
||||
# urls in the json have "agents" twice, so let's tidy that up here...
|
||||
ro["description"] = ro["description"].replace('https://darkvisitors.com/agents/agents/', 'https://darkvisitors.com/agents/')
|
||||
return bots
|
||||
|
||||
|
||||
def get_agent_soup():
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue