Zhu-FaceOnLive
commited on
Update app.py
Browse files
app.py
CHANGED
@@ -105,9 +105,10 @@ def process_response(response, soc_res, url, token):
|
|
105 |
return []
|
106 |
|
107 |
try:
|
108 |
-
res = response.json().get('img_array')
|
109 |
if soc_res:
|
110 |
res = soc_res[0] + res + soc_res[1]
|
|
|
111 |
suffix = "" if url == PREMIUM_URL else FREE_SUFFIX
|
112 |
out_array = check_db(res, suffix)
|
113 |
|
|
|
105 |
return []
|
106 |
|
107 |
try:
|
108 |
+
res = response.json().get('img_array', []) if status_code == 202 else []
|
109 |
if soc_res:
|
110 |
res = soc_res[0] + res + soc_res[1]
|
111 |
+
|
112 |
suffix = "" if url == PREMIUM_URL else FREE_SUFFIX
|
113 |
out_array = check_db(res, suffix)
|
114 |
|