this repo has no description
0
fork

Configure Feed

Select the types of activity you want to include in your feed.

Strip http(s):// and trailing slashes

alice 2dbdd9b8 404491d8

+5 -1
+5 -1
app.py
··· 106 106 107 107 @app.post("/fetch") 108 108 async def fetch_car_file(request: FetchRequest) -> str: 109 - did, pds = request.did, request.pds 109 + did, pds = request.did, request.pds.strip().lower().rstrip("/") 110 + if pds.startswith("https://"): 111 + pds = pds[8:] 112 + elif pds.startswith("http://"): 113 + pds = pds[7:] 110 114 url = f"https://{pds}/xrpc/com.atproto.sync.getRepo?did={did}" 111 115 headers = { 112 116 "Accept": "application/vnd.ipld.car",