nsfwalex commited on
Commit
94ea633
·
verified ·
1 Parent(s): ff50328

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +1 -1
app.py CHANGED
@@ -64,7 +64,7 @@ def swap_face(source_file, target_file, doFaceEnhancer, skey):
64
  raise Exception("verify authkey failed.")
65
  timestamp_requested = int(skey["t"])
66
  timestamp_now = int(datetime.datetime.utcnow().replace(tzinfo=datetime.timezone.utc).timestamp())
67
- if timestamp_now - timestamp_requested > 20:
68
  raise Exception(f"authkey timeout, {timestamp_now - timestamp_requested}")
69
  print(f"authkey pass, {timestamp_now - timestamp_requested}")
70
  source_path = "input.jpg"
 
64
  raise Exception("verify authkey failed.")
65
  timestamp_requested = int(skey["t"])
66
  timestamp_now = int(datetime.datetime.utcnow().replace(tzinfo=datetime.timezone.utc).timestamp())
67
+ if timestamp_now - timestamp_requested > 600:
68
  raise Exception(f"authkey timeout, {timestamp_now - timestamp_requested}")
69
  print(f"authkey pass, {timestamp_now - timestamp_requested}")
70
  source_path = "input.jpg"