File tree Expand file tree Collapse file tree 1 file changed +5
-1
lines changed
Expand file tree Collapse file tree 1 file changed +5
-1
lines changed Original file line number Diff line number Diff line change 1111use OCP \Capabilities \ICapability ;
1212use OCP \IUser ;
1313use OCP \IUserSession ;
14+ use OCP \App \IAppManager ;
1415
1516class Capabilities implements ICapability {
1617 private IUserSession $ userSession ;
1718 private FolderManager $ folderManager ;
19+ private IAppManager $ appManager ;
1820
19- public function __construct (IUserSession $ userSession , FolderManager $ folderManager ) {
21+ public function __construct (IUserSession $ userSession , FolderManager $ folderManager, IAppManager $ appManager ) {
2022 $ this ->userSession = $ userSession ;
2123 $ this ->folderManager = $ folderManager ;
24+ $ this ->appManager = $ appManager ;
2225 }
2326
2427 public function getCapabilities (): array {
@@ -28,6 +31,7 @@ public function getCapabilities(): array {
2831 }
2932 return [
3033 Application::APP_ID => [
34+ 'appVersion ' => $ this ->appManager ->getAppVersion (Application::APP_ID ),
3135 'hasGroupFolders ' => $ this ->hasFolders ($ user ),
3236 ],
3337 ];
You canβt perform that action at this time.
0 commit comments