File tree Expand file tree Collapse file tree 3 files changed +7
-20
lines changed
Expand file tree Collapse file tree 3 files changed +7
-20
lines changed Original file line number Diff line number Diff line change @@ -414,30 +414,15 @@ public function getBackend(): ?UserInterface {
414414 return $ this ->backend ;
415415 }
416416
417- /**
418- * Check if the backend allows the user to change their avatar on Personal page
419- *
420- * @return bool
421- */
422- public function canChangeAvatar () {
417+ public function canChangeAvatar (): bool {
423418 return $ this ->canEditProperty (IAccountManager::PROPERTY_AVATAR );
424419 }
425420
426- /**
427- * check if the backend supports changing passwords
428- *
429- * @return bool
430- */
431- public function canChangePassword () {
421+ public function canChangePassword (): bool {
432422 return $ this ->backend ->implementsActions (Backend::SET_PASSWORD );
433423 }
434424
435- /**
436- * check if the backend supports changing display names
437- *
438- * @return bool
439- */
440- public function canChangeDisplayName () {
425+ public function canChangeDisplayName (): bool {
441426 return $ this ->canEditProperty (IAccountManager::PROPERTY_DISPLAYNAME );
442427 }
443428
Original file line number Diff line number Diff line change 88namespace OCP ;
99
1010use InvalidArgumentException ;
11+ use OCP \Accounts \IAccountManager ;
1112use OCP \AppFramework \Attribute \Consumable ;
1213
1314/**
Original file line number Diff line number Diff line change 99
1010namespace OCP \User \Backend ;
1111
12- use OCP \Account \IAccountManager ;
12+ use OCP \Accounts \IAccountManager ;
13+ use OCP \AppFramework \Attribute \Consumable ;
1314use OCP \AppFramework \Attribute \Implementable ;
1415
1516/**
@@ -22,7 +23,7 @@ interface IPropertyPermissionBackend {
2223 * @since 34.0.0
2324 *
2425 * @param IAccountManager::PROPERTY_*|IAccountManager::COLLECTION_* $property
25- * @return Whether the user is allowed to edit its own property
26+ * @return bool Whether the user is allowed to edit its own property
2627 */
2728 public function canEditProperty (string $ uid , string $ property ): bool ;
2829}
You can’t perform that action at this time.
0 commit comments