@cryptotaxi247 / CoPilot / commits / 782c5af8

Create utils.py

taylor_socfortress committed Jul 10, 2023 at 16:48 UTC 782c5af8e10be5ac876035bd65bb32069022a9d5
1 file changed +3
backend/app/utils.py new
+3
@@ -0,0 +1,3 @@
1 +def allowed_file(filename):
2 + ALLOWED_EXTENSIONS = {"yaml", "txt"}
3 + return "." in filename and filename.rsplit(".", 1)[1].lower() in ALLOWED_EXTENSIONS