mirror of
https://github.com/StefBuwalda/WebTech.git
synced 2025-10-29 10:49:59 +00:00
Linux bug hotfix
Setting upload folder to a string with \ as separators caused issues on Linux based OS.
This commit is contained in:
@@ -9,7 +9,7 @@ app = Flask(__name__)
|
||||
app.config["SQLALCHEMY_DATABASE_URI"] = "sqlite:///services.sqlite"
|
||||
app.config["SQLALCHEMY_TRACK_MODIFICATIONS"] = False # Wat is dit?
|
||||
app.config["SECRET_KEY"] = "bvjchsygvduycgsyugc" # Andere secret key
|
||||
app.config["UPLOAD_FOLDER"] = r"application\static\icons"
|
||||
app.config["UPLOAD_FOLDER"] = os.path.join("application", "static", "icons")
|
||||
|
||||
# Ensure the upload folder exists
|
||||
os.makedirs(app.config["UPLOAD_FOLDER"], exist_ok=True) # type: ignore
|
||||
|
||||
Reference in New Issue
Block a user