Skip to content

Commit

Permalink
add convenience method to check if a file is in the hidden folder
Browse files Browse the repository at this point in the history
Signed-off-by: Robin Appelman <robin@icewind.nl>
  • Loading branch information
icewind1991 committed Aug 23, 2022
1 parent bbbbebf commit bbc4e4b
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions lib/private/Files/Filesystem.php
Original file line number Diff line number Diff line change
Expand Up @@ -818,4 +818,8 @@ public static function getETag($path) {
public static function getHiddenFolderName(): string {
return '.hidden_' . \OC_Util::getInstanceId();
}

public static function isPathHidden($path): string {
return strpos($path, self::getHiddenFolderName()) !== false;
}
}

0 comments on commit bbc4e4b

Please sign in to comment.