diff --git a/apps/cloud_federation_api/lib/Controller/RequestHandlerController.php b/apps/cloud_federation_api/lib/Controller/RequestHandlerController.php index a10dadbbdce68..0a536aec431c7 100644 --- a/apps/cloud_federation_api/lib/Controller/RequestHandlerController.php +++ b/apps/cloud_federation_api/lib/Controller/RequestHandlerController.php @@ -51,9 +51,9 @@ * * @package OCA\CloudFederationAPI\Controller * - * @psalm-import-type CloudFederationApiAddShare from ResponseDefinitions - * @psalm-import-type CloudFederationApiValidationError from ResponseDefinitions - * @psalm-import-type CloudFederationApiError from ResponseDefinitions + * @psalm-import-type CloudFederationAPIAddShare from ResponseDefinitions + * @psalm-import-type CloudFederationAPIValidationError from ResponseDefinitions + * @psalm-import-type CloudFederationAPIError from ResponseDefinitions */ class RequestHandlerController extends Controller { public function __construct( @@ -90,7 +90,7 @@ public function __construct( * @param string $shareType 'group' or 'user' share * @param string $resourceType 'file', 'calendar',... * - * @return JSONResponse|JSONResponse|JSONResponse + * @return JSONResponse|JSONResponse|JSONResponse * 201: The notification was successfully received. The display name of the recipient might be returned in the body * 400: Bad request due to invalid parameters, e.g. when `shareWith` is not found or required properties are missing * 501: Share type or the resource type is not supported @@ -213,7 +213,7 @@ public function addShare($shareWith, $name, $description, $providerId, $owner, $ * @param string|null $providerId ID of the share * @param array|null $notification The actual payload of the notification * - * @return JSONResponse, array{}>|JSONResponse|JSONResponse + * @return JSONResponse, array{}>|JSONResponse|JSONResponse * 201: The notification was successfully received * 400: Bad request due to invalid parameters, e.g. when `type` is invalid or missing * 403: Getting resource is not allowed diff --git a/apps/cloud_federation_api/lib/ResponseDefinitions.php b/apps/cloud_federation_api/lib/ResponseDefinitions.php index 06b8124cc3273..7f916d6c6cdb7 100644 --- a/apps/cloud_federation_api/lib/ResponseDefinitions.php +++ b/apps/cloud_federation_api/lib/ResponseDefinitions.php @@ -26,15 +26,15 @@ namespace OCA\CloudFederationAPI; /** - * @psalm-type CloudFederationApiAddShare = array{ + * @psalm-type CloudFederationAPIAddShare = array{ * recipientDisplayName: string, * } * - * @psalm-type CloudFederationApiError = array{ + * @psalm-type CloudFederationAPIError = array{ * message: string, * } * - * @psalm-type CloudFederationApiValidationError = CloudFederationApiError&array{ + * @psalm-type CloudFederationAPIValidationError = CloudFederationAPIError&array{ * validationErrors: array{ * name: string, * message: string|null, diff --git a/apps/files_external/lib/Controller/ApiController.php b/apps/files_external/lib/Controller/ApiController.php index 163d403dc2c4f..f9fbcdfeca80d 100644 --- a/apps/files_external/lib/Controller/ApiController.php +++ b/apps/files_external/lib/Controller/ApiController.php @@ -40,7 +40,7 @@ use OCP\IRequest; /** - * @psalm-import-type FilesExternalMount from ResponseDefinitions + * @psalm-import-type Files_ExternalMount from ResponseDefinitions */ class ApiController extends OCSController { @@ -64,7 +64,7 @@ public function __construct( * @param string $mountPoint mount point name, relative to the data dir * @param StorageConfig $mountConfig mount config to format * - * @return FilesExternalMount + * @return Files_ExternalMount */ private function formatMount(string $mountPoint, StorageConfig $mountConfig): array { // split path from mount point @@ -100,7 +100,7 @@ private function formatMount(string $mountPoint, StorageConfig $mountConfig): ar * * Get the mount points visible for this user * - * @return DataResponse + * @return DataResponse * * 200: User mounts returned */ diff --git a/apps/files_external/lib/Lib/StorageConfig.php b/apps/files_external/lib/Lib/StorageConfig.php index 25205a243212c..9e89e8fcc99bd 100644 --- a/apps/files_external/lib/Lib/StorageConfig.php +++ b/apps/files_external/lib/Lib/StorageConfig.php @@ -36,7 +36,7 @@ /** * External storage configuration * - * @psalm-import-type FilesExternalStorageConfig from ResponseDefinitions + * @psalm-import-type Files_ExternalStorageConfig from ResponseDefinitions */ class StorageConfig implements \JsonSerializable { public const MOUNT_TYPE_ADMIN = 1; @@ -399,7 +399,7 @@ public function setType($type) { /** * Serialize config to JSON - * @return FilesExternalStorageConfig + * @return Files_ExternalStorageConfig */ public function jsonSerialize(bool $obfuscate = false): array { $result = []; diff --git a/apps/files_external/lib/ResponseDefinitions.php b/apps/files_external/lib/ResponseDefinitions.php index cb501ed1bce22..2c86ed18e552c 100644 --- a/apps/files_external/lib/ResponseDefinitions.php +++ b/apps/files_external/lib/ResponseDefinitions.php @@ -26,7 +26,7 @@ namespace OCA\Files_External; /** - * @psalm-type FilesExternalStorageConfig = array{ + * @psalm-type Files_ExternalStorageConfig = array{ * applicableGroups?: string[], * applicableUsers?: string[], * authMechanism: string, @@ -42,7 +42,7 @@ * userProvided: bool, * } * - * @psalm-type FilesExternalMount = array{ + * @psalm-type Files_ExternalMount = array{ * name: string, * path: string, * type: 'dir', @@ -51,7 +51,7 @@ * permissions: int, * id: int, * class: string, - * config: FilesExternalStorageConfig, + * config: Files_ExternalStorageConfig, * } */ class ResponseDefinitions { diff --git a/apps/files_sharing/lib/Controller/DeletedShareAPIController.php b/apps/files_sharing/lib/Controller/DeletedShareAPIController.php index 47ff271c926b5..aec011aa7ac9e 100644 --- a/apps/files_sharing/lib/Controller/DeletedShareAPIController.php +++ b/apps/files_sharing/lib/Controller/DeletedShareAPIController.php @@ -51,7 +51,7 @@ use OCP\Share\IShare; /** - * @psalm-import-type FilesSharingDeletedShare from ResponseDefinitions + * @psalm-import-type Files_SharingDeletedShare from ResponseDefinitions */ class DeletedShareAPIController extends OCSController { @@ -99,7 +99,7 @@ public function __construct(string $appName, /** * @suppress PhanUndeclaredClassMethod * - * @return FilesSharingDeletedShare + * @return Files_SharingDeletedShare */ private function formatShare(IShare $share): array { $result = [ @@ -187,7 +187,7 @@ private function formatShare(IShare $share): array { * * Get a list of all deleted shares * - * @return DataResponse + * @return DataResponse * * 200: Deleted shares returned */ diff --git a/apps/files_sharing/lib/Controller/RemoteController.php b/apps/files_sharing/lib/Controller/RemoteController.php index bb8933e8426e4..b507bf6a04a0c 100644 --- a/apps/files_sharing/lib/Controller/RemoteController.php +++ b/apps/files_sharing/lib/Controller/RemoteController.php @@ -35,7 +35,7 @@ use Psr\Log\LoggerInterface; /** - * @psalm-import-type FilesSharingRemoteShare from ResponseDefinitions + * @psalm-import-type Files_SharingRemoteShare from ResponseDefinitions */ class RemoteController extends OCSController { /** @@ -61,7 +61,7 @@ public function __construct( * * Get list of pending remote shares * - * @return DataResponse + * @return DataResponse * * 200: Pending remote shares returned */ @@ -139,7 +139,7 @@ private static function extendShareInfo($share) { * * Get a list of accepted remote shares * - * @return DataResponse + * @return DataResponse * * 200: Accepted remote shares returned */ @@ -156,7 +156,7 @@ public function getShares() { * Get info of a remote share * * @param int $id ID of the share - * @return DataResponse + * @return DataResponse * @throws OCSNotFoundException Share not found * * 200: Share returned diff --git a/apps/files_sharing/lib/Controller/ShareAPIController.php b/apps/files_sharing/lib/Controller/ShareAPIController.php index ebf0038dda241..5b69d522545f1 100644 --- a/apps/files_sharing/lib/Controller/ShareAPIController.php +++ b/apps/files_sharing/lib/Controller/ShareAPIController.php @@ -91,7 +91,7 @@ /** * @package OCA\Files_Sharing\API * - * @psalm-import-type FilesSharingShare from ResponseDefinitions + * @psalm-import-type Files_SharingShare from ResponseDefinitions */ class ShareAPIController extends OCSController { @@ -177,7 +177,7 @@ public function __construct( * * @param \OCP\Share\IShare $share * @param Node|null $recipientNode - * @return FilesSharingShare + * @return Files_SharingShare * @throws NotFoundException In case the node can't be resolved. * * @suppress PhanUndeclaredClassMethod @@ -508,7 +508,7 @@ private function getCachedFederatedDisplayName(string $userId, bool $cacheOnly = * * @param string $id ID of the share * @param bool $include_tags Include tags in the share - * @return DataResponse + * @return DataResponse * @throws OCSNotFoundException Share not found * * 200: Share returned @@ -602,7 +602,7 @@ public function deleteShare(string $id): DataResponse { * @param string $label Label for the share (only used in link and email) * @param string|null $attributes Additional attributes for the share * - * @return DataResponse + * @return DataResponse * @throws OCSBadRequestException Unknown share type * @throws OCSException * @throws OCSForbiddenException Creating the share is not allowed @@ -879,7 +879,7 @@ public function createShare( * @param null|Node $node * @param boolean $includeTags * - * @return FilesSharingShare[] + * @return Files_SharingShare[] */ private function getSharedWithMe($node, bool $includeTags): array { $userShares = $this->shareManager->getSharedWith($this->currentUser, IShare::TYPE_USER, $node, -1, 0); @@ -916,7 +916,7 @@ private function getSharedWithMe($node, bool $includeTags): array { /** * @param \OCP\Files\Node $folder * - * @return FilesSharingShare[] + * @return Files_SharingShare[] * @throws OCSBadRequestException * @throws NotFoundException */ @@ -978,7 +978,7 @@ private function getSharesInDir(Node $folder): array { * @param string $path Get shares for a specific path * @param string $include_tags Include tags in the share * - * @return DataResponse + * @return DataResponse * @throws OCSNotFoundException The folder was not found or is inaccessible * * 200: Shares returned @@ -1026,7 +1026,7 @@ public function getShares( * @param bool $subFiles * @param bool $includeTags * - * @return FilesSharingShare[] + * @return Files_SharingShare[] * @throws NotFoundException * @throws OCSBadRequestException */ @@ -1111,7 +1111,7 @@ private function getFormattedShares( * * @param string $path Path all shares will be relative to * - * @return DataResponse + * @return DataResponse * @throws InvalidPathException * @throws NotFoundException * @throws OCSNotFoundException The given path is invalid @@ -1213,7 +1213,7 @@ private function hasPermission(int $permissionsSet, int $permissionsToCheck): bo * @param string|null $label New label * @param string|null $hideDownload New condition if the download should be hidden * @param string|null $attributes New additional attributes - * @return DataResponse + * @return DataResponse * @throws OCSBadRequestException Share could not be updated because the requested changes are invalid * @throws OCSForbiddenException Missing permissions to update the share * @throws OCSNotFoundException Share not found @@ -1409,7 +1409,7 @@ public function updateShare( * * Get all shares that are still pending * - * @return DataResponse + * @return DataResponse * * 200: Pending shares returned */ diff --git a/apps/files_sharing/lib/Controller/ShareInfoController.php b/apps/files_sharing/lib/Controller/ShareInfoController.php index 14f69b9703fcc..720705121d23b 100644 --- a/apps/files_sharing/lib/Controller/ShareInfoController.php +++ b/apps/files_sharing/lib/Controller/ShareInfoController.php @@ -38,7 +38,7 @@ use OCP\Share\IManager; /** - * @psalm-import-type FilesSharingShareInfo from ResponseDefinitions + * @psalm-import-type Files_SharingShareInfo from ResponseDefinitions */ class ShareInfoController extends ApiController { @@ -71,7 +71,7 @@ public function __construct(string $appName, * @param string|null $password Password of the share * @param string|null $dir Subdirectory to get info about * @param int $depth Maximum depth to get info about - * @return JSONResponse|JSONResponse, array{}> + * @return JSONResponse|JSONResponse, array{}> * * 200: Share info returned * 403: Getting share info is not allowed @@ -112,7 +112,7 @@ public function info(string $t, ?string $password = null, ?string $dir = null, i } /** - * @return FilesSharingShareInfo + * @return Files_SharingShareInfo */ private function parseNode(Node $node, int $permissionMask, int $depth): array { if ($node instanceof File) { @@ -123,14 +123,14 @@ private function parseNode(Node $node, int $permissionMask, int $depth): array { } /** - * @return FilesSharingShareInfo + * @return Files_SharingShareInfo */ private function parseFile(File $file, int $permissionMask): array { return $this->format($file, $permissionMask); } /** - * @return FilesSharingShareInfo + * @return Files_SharingShareInfo */ private function parseFolder(Folder $folder, int $permissionMask, int $depth): array { $data = $this->format($folder, $permissionMask); @@ -150,7 +150,7 @@ private function parseFolder(Folder $folder, int $permissionMask, int $depth): a } /** - * @return FilesSharingShareInfo + * @return Files_SharingShareInfo */ private function format(Node $node, int $permissionMask): array { $entry = []; diff --git a/apps/files_sharing/lib/Controller/ShareesAPIController.php b/apps/files_sharing/lib/Controller/ShareesAPIController.php index 76787a26f103f..c151ab533273c 100644 --- a/apps/files_sharing/lib/Controller/ShareesAPIController.php +++ b/apps/files_sharing/lib/Controller/ShareesAPIController.php @@ -59,8 +59,8 @@ use function usort; /** - * @psalm-import-type FilesSharingShareesSearchResult from ResponseDefinitions - * @psalm-import-type FilesSharingShareesRecommendedResult from ResponseDefinitions + * @psalm-import-type Files_SharingShareesSearchResult from ResponseDefinitions + * @psalm-import-type Files_SharingShareesRecommendedResult from ResponseDefinitions */ class ShareesAPIController extends OCSController { @@ -82,7 +82,7 @@ class ShareesAPIController extends OCSController { /** @var int */ protected $limit = 10; - /** @var FilesSharingShareesSearchResult */ + /** @var Files_SharingShareesSearchResult */ protected $result = [ 'exact' => [ 'users' => [], @@ -145,7 +145,7 @@ public function __construct( * @param int $perPage Limit amount of search results per page * @param int|int[]|null $shareType Limit to specific share types * @param bool $lookup If a global lookup should be performed too - * @return DataResponse + * @return DataResponse * @throws OCSBadRequestException Invalid search parameters * * 200: Sharees search result returned @@ -347,7 +347,7 @@ private function getAllSharees(string $user, array $shareTypes): ISearchResult { * * @param string $itemType Limit to specific item types * @param int|int[]|null $shareType Limit to specific share types - * @return DataResponse + * @return DataResponse * * 200: Recommended sharees returned */ diff --git a/apps/files_sharing/lib/ResponseDefinitions.php b/apps/files_sharing/lib/ResponseDefinitions.php index e2e5d6d7ba39c..19993572c2e42 100644 --- a/apps/files_sharing/lib/ResponseDefinitions.php +++ b/apps/files_sharing/lib/ResponseDefinitions.php @@ -26,7 +26,7 @@ namespace OCA\Files_Sharing; /** - * @psalm-type FilesSharingShare = array{ + * @psalm-type Files_SharingShare = array{ * attributes: ?string, * can_delete: bool, * can_edit: bool, @@ -70,7 +70,7 @@ * url?: string, * } * - * @psalm-type FilesSharingDeletedShare = array{ + * @psalm-type Files_SharingDeletedShare = array{ * id: string, * share_type: int, * uid_owner: string, @@ -93,7 +93,7 @@ * share_with_link: string|null, * } * - * @psalm-type FilesSharingRemoteShare = array{ + * @psalm-type Files_SharingRemoteShare = array{ * accepted: bool, * file_id: int|null, * id: int, @@ -112,17 +112,17 @@ * user: string, * } * - * @psalm-type FilesSharingSharee = array{ + * @psalm-type Files_SharingSharee = array{ * count: int|null, * label: string, * } * - * @psalm-type FilesSharingShareeValue = array{ + * @psalm-type Files_SharingShareeValue = array{ * shareType: int, * shareWith: string, * } * - * @psalm-type FilesSharingShareeUser = FilesSharingSharee&array{ + * @psalm-type Files_SharingShareeUser = Files_SharingSharee&array{ * subline: string, * icon: string, * shareWithDisplayNameUnique: string, @@ -132,101 +132,101 @@ * icon: string, * clearAt: int|null, * }, - * value: FilesSharingShareeValue, + * value: Files_SharingShareeValue, * } * - * @psalm-type FilesSharingShareeRemoteGroup = FilesSharingSharee&array{ + * @psalm-type Files_SharingShareeRemoteGroup = Files_SharingSharee&array{ * guid: string, * name: string, - * value: FilesSharingShareeValue&array{ + * value: Files_SharingShareeValue&array{ * server: string, * } * } * - * @psalm-type FilesSharingLookup = array{ + * @psalm-type Files_SharingLookup = array{ * value: string, * verified: int, * } * - * @psalm-type FilesSharingShareeLookup = FilesSharingSharee&array{ + * @psalm-type Files_SharingShareeLookup = Files_SharingSharee&array{ * extra: array{ * federationId: string, - * name: FilesSharingLookup|null, - * email: FilesSharingLookup|null, - * address: FilesSharingLookup|null, - * website: FilesSharingLookup|null, - * twitter: FilesSharingLookup|null, - * phone: FilesSharingLookup|null, - * twitter_signature: FilesSharingLookup|null, - * website_signature: FilesSharingLookup|null, - * userid: FilesSharingLookup|null, + * name: Files_SharingLookup|null, + * email: Files_SharingLookup|null, + * address: Files_SharingLookup|null, + * website: Files_SharingLookup|null, + * twitter: Files_SharingLookup|null, + * phone: Files_SharingLookup|null, + * twitter_signature: Files_SharingLookup|null, + * website_signature: Files_SharingLookup|null, + * userid: Files_SharingLookup|null, * }, - * value: FilesSharingShareeValue&array{ + * value: Files_SharingShareeValue&array{ * globalScale: bool, * } * } * - * @psalm-type FilesSharingShareeEmail = FilesSharingSharee&array{ + * @psalm-type Files_SharingShareeEmail = Files_SharingSharee&array{ * uuid: string, * name: string, * type: string, * shareWithDisplayNameUnique: string, - * value: FilesSharingShareeValue, + * value: Files_SharingShareeValue, * } * - * @psalm-type FilesSharingShareeRemote = FilesSharingSharee&array{ + * @psalm-type Files_SharingShareeRemote = Files_SharingSharee&array{ * uuid: string, * name: string, * type: string, - * value: FilesSharingShareeValue&array{ + * value: Files_SharingShareeValue&array{ * server: string, * } * } * - * @psalm-type FilesSharingShareeCircle = FilesSharingSharee&array{ + * @psalm-type Files_SharingShareeCircle = Files_SharingSharee&array{ * shareWithDescription: string, - * value: FilesSharingShareeValue&array{ + * value: Files_SharingShareeValue&array{ * circle: string, * } * } * - * @psalm-type FilesSharingShareesSearchResult = array{ + * @psalm-type Files_SharingShareesSearchResult = array{ * exact: array{ - * circles: FilesSharingShareeCircle[], - * emails: FilesSharingShareeEmail[], - * groups: FilesSharingSharee[], - * remote_groups: FilesSharingShareeRemoteGroup[], - * remotes: FilesSharingShareeRemote[], - * rooms: FilesSharingSharee[], - * users: FilesSharingShareeUser[], + * circles: Files_SharingShareeCircle[], + * emails: Files_SharingShareeEmail[], + * groups: Files_SharingSharee[], + * remote_groups: Files_SharingShareeRemoteGroup[], + * remotes: Files_SharingShareeRemote[], + * rooms: Files_SharingSharee[], + * users: Files_SharingShareeUser[], * }, - * circles: FilesSharingShareeCircle[], - * emails: FilesSharingShareeEmail[], - * groups: FilesSharingSharee[], - * lookup: FilesSharingShareeLookup[], - * remote_groups: FilesSharingShareeRemoteGroup[], - * remotes: FilesSharingShareeRemote[], - * rooms: FilesSharingSharee[], - * users: FilesSharingShareeUser[], + * circles: Files_SharingShareeCircle[], + * emails: Files_SharingShareeEmail[], + * groups: Files_SharingSharee[], + * lookup: Files_SharingShareeLookup[], + * remote_groups: Files_SharingShareeRemoteGroup[], + * remotes: Files_SharingShareeRemote[], + * rooms: Files_SharingSharee[], + * users: Files_SharingShareeUser[], * lookupEnabled: bool, * } * - * @psalm-type FilesSharingShareesRecommendedResult = array{ + * @psalm-type Files_SharingShareesRecommendedResult = array{ * exact: array{ - * emails: FilesSharingShareeEmail[], - * groups: FilesSharingSharee[], - * remote_groups: FilesSharingShareeRemoteGroup[], - * remotes: FilesSharingShareeRemote[], - * users: FilesSharingShareeUser[], + * emails: Files_SharingShareeEmail[], + * groups: Files_SharingSharee[], + * remote_groups: Files_SharingShareeRemoteGroup[], + * remotes: Files_SharingShareeRemote[], + * users: Files_SharingShareeUser[], * }, - * emails: FilesSharingShareeEmail[], - * groups: FilesSharingSharee[], - * remote_groups: FilesSharingShareeRemoteGroup[], - * remotes: FilesSharingShareeRemote[], - * users: FilesSharingShareeUser[], + * emails: Files_SharingShareeEmail[], + * groups: Files_SharingSharee[], + * remote_groups: Files_SharingShareeRemoteGroup[], + * remotes: Files_SharingShareeRemote[], + * users: Files_SharingShareeUser[], * } * - * @psalm-type FilesSharingShareInfo = array{ + * @psalm-type Files_SharingShareInfo = array{ * id: int, * parentId: int, * mtime: int, diff --git a/apps/provisioning_api/lib/Controller/AUserData.php b/apps/provisioning_api/lib/Controller/AUserData.php index 7ce1484cf714c..584ff9a8cc769 100644 --- a/apps/provisioning_api/lib/Controller/AUserData.php +++ b/apps/provisioning_api/lib/Controller/AUserData.php @@ -54,8 +54,8 @@ use OCP\User\Backend\ISetPasswordBackend; /** - * @psalm-import-type ProvisioningApiUserDetails from ResponseDefinitions - * @psalm-import-type ProvisioningApiUserDetailsQuota from ResponseDefinitions + * @psalm-import-type Provisioning_APIUserDetails from ResponseDefinitions + * @psalm-import-type Provisioning_APIUserDetailsQuota from ResponseDefinitions */ abstract class AUserData extends OCSController { public const SCOPE_SUFFIX = 'Scope'; @@ -104,7 +104,7 @@ public function __construct(string $appName, * * @param string $userId * @param bool $includeScopes - * @return ProvisioningApiUserDetails|null + * @return Provisioning_APIUserDetails|null * @throws NotFoundException * @throws OCSException * @throws OCSNotFoundException @@ -252,7 +252,7 @@ protected function getUserSubAdminGroupsData(string $userId): array { /** * @param string $userId - * @return ProvisioningApiUserDetailsQuota + * @return Provisioning_APIUserDetailsQuota * @throws OCSException */ protected function fillStorageInfo(string $userId): array { diff --git a/apps/provisioning_api/lib/Controller/AppsController.php b/apps/provisioning_api/lib/Controller/AppsController.php index 893a17d684e17..534b164426222 100644 --- a/apps/provisioning_api/lib/Controller/AppsController.php +++ b/apps/provisioning_api/lib/Controller/AppsController.php @@ -40,7 +40,7 @@ use OCP\IRequest; /** - * @psalm-import-type ProvisioningApiAppInfo from ResponseDefinitions + * @psalm-import-type Provisioning_APIAppInfo from ResponseDefinitions */ class AppsController extends OCSController { /** @var IAppManager */ @@ -94,7 +94,7 @@ public function getApps(?string $filter = null): DataResponse { * Get the app info for an app * * @param string $app ID of the app - * @return DataResponse + * @return DataResponse * @throws OCSException * * 200: App info returned diff --git a/apps/provisioning_api/lib/Controller/GroupsController.php b/apps/provisioning_api/lib/Controller/GroupsController.php index 7b0e36ecec579..4fde392791666 100644 --- a/apps/provisioning_api/lib/Controller/GroupsController.php +++ b/apps/provisioning_api/lib/Controller/GroupsController.php @@ -52,8 +52,8 @@ use Psr\Log\LoggerInterface; /** - * @psalm-import-type ProvisioningApiGroupDetails from ResponseDefinitions - * @psalm-import-type ProvisioningApiUserDetails from ResponseDefinitions + * @psalm-import-type Provisioning_APIGroupDetails from ResponseDefinitions + * @psalm-import-type Provisioning_APIUserDetails from ResponseDefinitions */ class GroupsController extends AUserData { @@ -113,7 +113,7 @@ public function getGroups(string $search = '', ?int $limit = null, int $offset = * @param string $search Text to search for * @param ?int $limit Limit the amount of groups returned * @param int $offset Offset for searching for groups - * @return DataResponse + * @return DataResponse * * 200: Groups details returned */ @@ -204,7 +204,7 @@ public function getGroupUsers(string $groupId): DataResponse { * @param int|null $limit Limit the amount of groups returned * @param int $offset Offset for searching for groups * - * @return DataResponse}, array{}> + * @return DataResponse}, array{}> * @throws OCSException * * 200: Group users details returned diff --git a/apps/provisioning_api/lib/Controller/UsersController.php b/apps/provisioning_api/lib/Controller/UsersController.php index 97d94ecb407d2..352970faa37a1 100644 --- a/apps/provisioning_api/lib/Controller/UsersController.php +++ b/apps/provisioning_api/lib/Controller/UsersController.php @@ -76,7 +76,7 @@ use Psr\Log\LoggerInterface; /** - * @psalm-import-type ProvisioningApiUserDetails from ResponseDefinitions + * @psalm-import-type Provisioning_APIUserDetails from ResponseDefinitions */ class UsersController extends AUserData { /** @var IURLGenerator */ @@ -184,7 +184,7 @@ public function getUsers(string $search = '', int $limit = null, int $offset = 0 * @param string $search Text to search for * @param int|null $limit Limit the amount of groups returned * @param int $offset Offset for searching for groups - * @return DataResponse}, array{}> + * @return DataResponse}, array{}> * * 200: Users details returned */ @@ -237,7 +237,7 @@ public function getUsersDetails(string $search = '', int $limit = null, int $off * * @param ?int $limit Limit the amount of users returned * @param int $offset Offset - * @return DataResponse}, array{}> + * @return DataResponse}, array{}> * * 200: Disabled users details returned */ @@ -611,7 +611,7 @@ public function addUser( * Get the details of a user * * @param string $userId ID of the user - * @return DataResponse + * @return DataResponse * @throws OCSException * * 200: User returned @@ -637,7 +637,7 @@ public function getUser(string $userId): DataResponse { * * Get the details of the current user * - * @return DataResponse + * @return DataResponse * @throws OCSException * * 200: Current user returned @@ -645,7 +645,7 @@ public function getUser(string $userId): DataResponse { public function getCurrentUser(): DataResponse { $user = $this->userSession->getUser(); if ($user) { - /** @var ProvisioningApiUserDetails $data */ + /** @var Provisioning_APIUserDetails $data */ $data = $this->getUserData($user->getUID(), true); return new DataResponse($data); } diff --git a/apps/provisioning_api/lib/ResponseDefinitions.php b/apps/provisioning_api/lib/ResponseDefinitions.php index 071faee59769c..43e95c52e069f 100644 --- a/apps/provisioning_api/lib/ResponseDefinitions.php +++ b/apps/provisioning_api/lib/ResponseDefinitions.php @@ -26,7 +26,7 @@ namespace OCA\Provisioning_API; /** - * @psalm-type ProvisioningApiUserDetailsQuota = array{ + * @psalm-type Provisioning_APIUserDetailsQuota = array{ * free?: float|int, * quota?: float|int|string, * relative?: float|int, @@ -34,7 +34,7 @@ * used?: float|int, * } * - * @psalm-type ProvisioningApiUserDetails = array{ + * @psalm-type Provisioning_APIUserDetails = array{ * additional_mail: string[], * additional_mailScope?: string[], * address: string, @@ -70,7 +70,7 @@ * phoneScope?: string, * profile_enabled: string, * profile_enabledScope?: string, - * quota: ProvisioningApiUserDetailsQuota, + * quota: Provisioning_APIUserDetailsQuota, * role: string, * roleScope?: string, * storageLocation?: string, @@ -81,7 +81,7 @@ * websiteScope?: string, * } * - * @psalm-type ProvisioningApiAppInfo = array{ + * @psalm-type Provisioning_APIAppInfo = array{ * active: bool|null, * activity: ?mixed, * author: ?mixed, @@ -123,7 +123,7 @@ * website: ?mixed, * } * - * @psalm-type ProvisioningApiGroupDetails = array{ + * @psalm-type Provisioning_APIGroupDetails = array{ * id: string, * displayname: string, * usercount: bool|int, diff --git a/apps/updatenotification/lib/Controller/APIController.php b/apps/updatenotification/lib/Controller/APIController.php index 8833f6e772e0c..f9e1252505381 100644 --- a/apps/updatenotification/lib/Controller/APIController.php +++ b/apps/updatenotification/lib/Controller/APIController.php @@ -39,7 +39,7 @@ use OCP\L10N\IFactory; /** - * @psalm-import-type UpdatenotificationApp from ResponseDefinitions + * @psalm-import-type UpdateNotificationApp from ResponseDefinitions */ class APIController extends OCSController { @@ -94,7 +94,7 @@ public function __construct(string $appName, * * @param string $newVersion Server version to check updates for * - * @return DataResponse|DataResponse + * @return DataResponse|DataResponse * * 200: Apps returned * 404: New versions not found @@ -167,7 +167,7 @@ public function getAppList(string $newVersion): DataResponse { * Get translated app name * * @param string $appId - * @return UpdatenotificationApp + * @return UpdateNotificationApp */ protected function getAppDetails(string $appId): array { $app = $this->appManager->getAppInfo($appId, false, $this->language); diff --git a/apps/updatenotification/lib/ResponseDefinitions.php b/apps/updatenotification/lib/ResponseDefinitions.php index 01b16b81dd053..cb6796aac34be 100644 --- a/apps/updatenotification/lib/ResponseDefinitions.php +++ b/apps/updatenotification/lib/ResponseDefinitions.php @@ -26,7 +26,7 @@ namespace OCA\UpdateNotification; /** - * @psalm-type UpdatenotificationApp = array{ + * @psalm-type UpdateNotificationApp = array{ * appId: string, * appName: string, * }