修复异常问题

qrnn
youngS 3 years ago
parent 86467ef2fd
commit bbf9664fc7
  1. 5
      fir_ser/api/utils/modelutils.py
  2. 3
      fir_ser/api/utils/storage/caches.py
  3. 2
      fir_ser/api/views/download.py

@ -88,7 +88,10 @@ def add_remote_info_from_request(request, description):
'a_domain': get_origin_domain_name(request)[0:127], 'a_domain': get_origin_domain_name(request)[0:127],
'description': description[0:255] 'description': description[0:255]
} }
RemoteClientInfo.objects.create(**remote_info) try:
RemoteClientInfo.objects.create(**remote_info)
except Exception as e:
logger.error(e)
def get_redirect_server_domain(request, user_obj=None, app_domain_name=None): def get_redirect_server_domain(request, user_obj=None, app_domain_name=None):

@ -117,7 +117,8 @@ def get_app_instance_by_cache(app_id, password, limit, udid):
if app_obj_cache: if app_obj_cache:
app_obj_cache['d_count'] = get_app_d_count_by_app_id(app_id) app_obj_cache['d_count'] = get_app_d_count_by_app_id(app_id)
cache.set(app_key, app_obj_cache, limit) cache.set(app_key, app_obj_cache, limit)
if not app_obj_cache:
return None
app_password = app_obj_cache.get("password") app_password = app_obj_cache.get("password")
if not check_app_password(app_password, password): if not check_app_password(app_password, password):

@ -224,7 +224,7 @@ class InstallView(APIView):
password = query_params.get("password", None) password = query_params.get("password", None)
udid = query_params.get("udid", None) udid = query_params.get("udid", None)
if not downtoken or not short or not release_id: if not downtoken or not short or not release_id or not app_id:
res.code = 1004 res.code = 1004
res.msg = "参数丢失" res.msg = "参数丢失"
return Response(res.dict) return Response(res.dict)

Loading…
Cancel
Save