Spaces:
Runtime error
Runtime error
fix
Browse files- user_history.py +1 -1
user_history.py
CHANGED
@@ -388,7 +388,7 @@ def _fetch_admins() -> List[str]:
|
|
388 |
# Running in Space => try to fetch organization members
|
389 |
# Otherwise, it's not an organization => namespace is the user
|
390 |
namespace = space_id.split("/")[0]
|
391 |
-
response = requests.get("https://huggingface.co/api/organizations/{namespace}/members")
|
392 |
if response.status_code == 200:
|
393 |
return sorted(member["user"] for member in response.json())
|
394 |
return [namespace]
|
|
|
388 |
# Running in Space => try to fetch organization members
|
389 |
# Otherwise, it's not an organization => namespace is the user
|
390 |
namespace = space_id.split("/")[0]
|
391 |
+
response = requests.get(f"https://huggingface.co/api/organizations/{namespace}/members")
|
392 |
if response.status_code == 200:
|
393 |
return sorted(member["user"] for member in response.json())
|
394 |
return [namespace]
|