File tree 2 files changed +12
-2
lines changed
packages/backend/src/filesystem
2 files changed +12
-2
lines changed Original file line number Diff line number Diff line change @@ -162,6 +162,17 @@ module.exports = class FSNodeContext {
162
162
if ( this . found === false ) return undefined ;
163
163
return ! this . entry . parent_uid ;
164
164
}
165
+
166
+ async getUserPart ( ) {
167
+ if ( this . isRoot ) return ;
168
+
169
+ let path = await this . get ( 'path' ) ;
170
+ if ( path . startsWith ( '/' ) ) path = path . slice ( 1 ) ;
171
+ const components = path . split ( '/' ) ;
172
+ const userpart = components [ 0 ] ;
173
+
174
+ return userpart ;
175
+ }
165
176
166
177
async exists ( fetch_options = { } ) {
167
178
await this . fetchEntry ( ) ;
Original file line number Diff line number Diff line change @@ -53,8 +53,7 @@ class HLReadDir extends HLFilesystemOperation {
53
53
const ll_listusers = new LLListUsers ( ) ;
54
54
children = await ll_listusers . run ( this . values ) ;
55
55
} else if (
56
- await subject . isUserDirectory ( ) &&
57
- await subject . get ( 'name' ) !== user . username
56
+ await subject . getUserPart ( ) !== user . username
58
57
) {
59
58
this . log . noticeme ( 'THIS HAPPEN' ) ;
60
59
const ll_readshares = new LLReadShares ( ) ;
You can’t perform that action at this time.
0 commit comments