chenjunkai 5 роки тому
батько
коміт
2d4fccbeef
1 змінених файлів з 1 додано та 1 видалено
  1. 1 1
      Controller/DetectController.py

+ 1 - 1
Controller/DetectController.py

@@ -445,7 +445,7 @@ class NotificationView(View):
         try:
             print('---')
 
-            cli = apns2.APNSClient(mode="dev", client_cert=os.path.join(BASE_DIR, APNS_CONFIG[appBundleId]['pem_path']))
+            cli = apns2.APNSClient(mode=APNS_MODE, client_cert=os.path.join(BASE_DIR, APNS_CONFIG[appBundleId]['pem_path']))
             # password=APNS_CONFIG[appBundleId]['password'])
             push_data = {"alert": "Motion ", "event_time": n_time, "event_type": event_type, "msg": "",
                          "received_at": n_time, "sound": "sound.aif", "uid": uid, "zpush": "1", "channel": channel}