Spaces:
Running
Running
Commit
·
45e28dd
1
Parent(s):
23cec4c
Implement null none handling
Browse filesSigned-off-by: Aivin V. Solatorio <avsolatorio@gmail.com>
- services.py +6 -0
services.py
CHANGED
|
@@ -328,6 +328,12 @@ def get_data360_link(
|
|
| 328 |
A dictionary with keys `url` containing a link to the Data360 page for the given indicator id (idno) with the optional parameters.
|
| 329 |
"""
|
| 330 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 331 |
hf_send_post(
|
| 332 |
dict(
|
| 333 |
method="get_data360_link",
|
|
|
|
| 328 |
A dictionary with keys `url` containing a link to the Data360 page for the given indicator id (idno) with the optional parameters.
|
| 329 |
"""
|
| 330 |
|
| 331 |
+
if str(year).lower().strip() in ("none", "null", "undefined"):
|
| 332 |
+
year = None
|
| 333 |
+
|
| 334 |
+
if str(country_codes).lower().strip() in ("none", "null", "undefined"):
|
| 335 |
+
country_codes = None
|
| 336 |
+
|
| 337 |
hf_send_post(
|
| 338 |
dict(
|
| 339 |
method="get_data360_link",
|