Переглянути джерело

Fix api_server: get_dialogue_history param

StrayWarrior 1 місяць тому
батько
коміт
81c3316c13
1 змінених файлів з 1 додано та 1 видалено
  1. 1 1
      api_server.py

+ 1 - 1
api_server.py

@@ -79,7 +79,7 @@ def list_users():
 def get_dialogue_history():
     staff_id = request.args['staff_id']
     user_id = request.args['user_id']
-    recent_minutes = request.args.get('recent_minutes', 1440)
+    recent_minutes = int(request.args.get('recent_minutes', 1440))
     dialogue_history = app.history_dialogue_service.get_dialogue_history(staff_id, user_id, recent_minutes)
     return jsonify({'code': 200, 'data': dialogue_history})