Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
@@ -1271,8 +1271,7 @@ def directory_exists(repo_id, directory, token):
|
|
1271 |
|
1272 |
|
1273 |
from datetime import datetime
|
1274 |
-
|
1275 |
-
|
1276 |
# List all files in the repository
|
1277 |
files = api.list_repo_files(repo_id=repo_id, repo_type="space", token=token)
|
1278 |
# Check if any file starts with the directory path
|
|
|
1271 |
|
1272 |
|
1273 |
from datetime import datetime
|
1274 |
+
api= new HFApi()
|
|
|
1275 |
# List all files in the repository
|
1276 |
files = api.list_repo_files(repo_id=repo_id, repo_type="space", token=token)
|
1277 |
# Check if any file starts with the directory path
|