Browse Source

Make upload files private by default

This unchecks the private box when uploading files by default. It's better to accidentally attach as private something that is meant to be public than to accidentally attach something as public which is meant to be private.
version-14
bcornwellmott 8 years ago
committed by GitHub
parent
commit
264af6ad3d
1 changed files with 2 additions and 2 deletions
  1. +2
    -2
      frappe/public/js/frappe/upload.js

+ 2
- 2
frappe/public/js/frappe/upload.js View File

@@ -53,7 +53,7 @@ frappe.upload = {
$uploaded_files_wrapper.removeClass('hidden').empty(); $uploaded_files_wrapper.removeClass('hidden').empty();


file_array = file_array.map( file_array = file_array.map(
file => Object.assign(file, {is_private: opts.is_private || 0})
file => Object.assign(file, {is_private: opts.is_private || 1})
) )
$upload.data('attached_files', file_array); $upload.data('attached_files', file_array);


@@ -379,4 +379,4 @@ frappe.upload = {
d.show(); d.show();
opts.confirm_is_private = 0; opts.confirm_is_private = 0;
} }
}
}

Loading…
Cancel
Save