vsmdvic commited on
Commit
2ac48fc
·
verified ·
1 Parent(s): dd4f884

Upload 5 files

Browse files
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -319,12 +319,12 @@ threading.Thread(target=cleanup_old_files, daemon=True).start()
319
  def index(): return send_from_directory("static", "index.html")
320
 
321
  @app.errorhandler(404)
322
- def not_found(e): return send_from_directory("static", "404.html"), 404
323
 
324
  @app.route("/<path:filename>")
325
  def serve_files(filename):
326
  try: return send_from_directory("static", filename)
327
- except: return send_from_directory("static", "404.html"), 404
328
 
329
  if __name__ == "__main__":
330
  app.run(host="0.0.0.0", port=7860, debug=False)
 
319
  def index(): return send_from_directory("static", "index.html")
320
 
321
  @app.errorhandler(404)
322
+ def not_found(e): return send_from_directory("static", "503.html"), 404
323
 
324
  @app.route("/<path:filename>")
325
  def serve_files(filename):
326
  try: return send_from_directory("static", filename)
327
+ except: return send_from_directory("static", "503.html"), 404
328
 
329
  if __name__ == "__main__":
330
  app.run(host="0.0.0.0", port=7860, debug=False)