Spaces:
Sleeping
Sleeping
Commit ·
e22407f
1
Parent(s): c7a1c65
Fix UI error crash when clearing form by preventing full dataset load in get_udise_choices
Browse files- hf_reader.py +3 -0
hf_reader.py
CHANGED
|
@@ -351,6 +351,9 @@ def search_udise(udise_code: str, marksheet_name: str = "") -> list[dict]:
|
|
| 351 |
|
| 352 |
def get_udise_choices(state: str, district: str, block: str, village: str = None) -> list[str]:
|
| 353 |
"""Returns a list of 'UDISE - School Name' for the given location filter."""
|
|
|
|
|
|
|
|
|
|
| 354 |
_ensure_loaded()
|
| 355 |
|
| 356 |
dfs_to_process = []
|
|
|
|
| 351 |
|
| 352 |
def get_udise_choices(state: str, district: str, block: str, village: str = None) -> list[str]:
|
| 353 |
"""Returns a list of 'UDISE - School Name' for the given location filter."""
|
| 354 |
+
if not state:
|
| 355 |
+
return []
|
| 356 |
+
|
| 357 |
_ensure_loaded()
|
| 358 |
|
| 359 |
dfs_to_process = []
|