mirror of
https://github.com/HeyPuter/puter
synced 2024-11-14 22:06:00 +00:00
feat: make public folders a config opt-in
This commit is contained in:
parent
461ea3eae6
commit
209555c1d9
@ -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
|
||||
|
Loading…
Reference in New Issue
Block a user