Shared With case:
We want to add another if block here to check if the file itself has been shared with anyone and to validate that with frappe.session.user.
Folder Shared With case:
Check if the parent folder has been explicitly shared with frappe.session.user. If there are noshared_with users, recursively check the parent folder until a shared_with value is found, and if frappe.session.user is present, otherwise deny.
https://github.com/agritheory/cloud_storage/blob/version-14/cloud_storage/cloud_storage/overrides/file.py#L32
Shared With case: We want to add another if block here to check if the file itself has been shared with anyone and to validate that with
frappe.session.user
.Folder Shared With case: Check if the parent folder has been explicitly shared with frappe.session.user. If there are no
shared_with
users, recursively check the parent folder until ashared_with
value is found, and iffrappe.session.user
is present, otherwise deny.