fix: not permitted error when code is edited
This was caused by auto-save when the user is not logged in. Fixed it by disabling auto-save for guest users.
This commit is contained in:
@@ -73,6 +73,10 @@
|
||||
codemirror: true,
|
||||
userdata: data,
|
||||
autosave: function(editor, code) {
|
||||
// can't autosave when user is Guest
|
||||
if (frappe.session.user == "Guest") {
|
||||
return;
|
||||
}
|
||||
var data = editor.options.userdata;
|
||||
var code = editor.codemirror.doc.getValue();
|
||||
// console.log("autosaving...")
|
||||
|
||||
Reference in New Issue
Block a user