mirror of
https://github.com/HeyPuter/puter.git
synced 2026-05-03 13:40:50 -05:00
feat: make public folders a config opt-in
This commit is contained in:
@@ -56,9 +56,11 @@ class ACLService extends BaseService {
|
||||
}
|
||||
|
||||
// Hard rule: anyone and anything can read /user/public directories
|
||||
const public_modes = ['read', 'list', 'see'];
|
||||
if ( public_modes.includes(mode) ) {
|
||||
if ( await fsNode.isPublic() ) return true;
|
||||
if ( this.global_config.enable_public_folders ) {
|
||||
const public_modes = ['read', 'list', 'see'];
|
||||
if ( public_modes.includes(mode) ) {
|
||||
if ( await fsNode.isPublic() ) return true;
|
||||
}
|
||||
}
|
||||
|
||||
// Access tokens only work if the authorizer has permission
|
||||
|
||||
Reference in New Issue
Block a user