Skip to content

Commit

Permalink
Disable read-only
Browse files Browse the repository at this point in the history
  • Loading branch information
XtramCZ committed Jun 30, 2023
1 parent 8fa47ca commit f429dbf
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion webapp.py
Original file line number Diff line number Diff line change
Expand Up @@ -209,9 +209,10 @@ def write_new_script(request):
@web_app.route("/delete/<filename>")
def delete(request, filename):
print("Deleting ", filename)
storage.remount("/",readonly=False)
os.remove(filename)
response = response_html.format("Deleted script " + filename)

storage.remount("/",readonly=True)
return("200 OK",[('Content-Type', 'text/html')], response)

@web_app.route("/run/<filename>")
Expand Down

0 comments on commit f429dbf

Please sign in to comment.