Skip to content

Commit

Permalink
Revert "[11.9] Add support for access_level in `Projects::createPro…
Browse files Browse the repository at this point in the history
…jectAccessToken` (GitLabPHP#731)"

This reverts commit f788d19.
  • Loading branch information
GrahamCampbell committed Mar 6, 2023
1 parent f788d19 commit c41ba94
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 7 deletions.
6 changes: 0 additions & 6 deletions src/Api/Projects.php
Original file line number Diff line number Diff line change
Expand Up @@ -1468,7 +1468,6 @@ public function projectAccessToken($project_id, $token_id)
*
* @var string $name the name of the project access token
* @var array $scopes the scopes, one or many of: api, read_api, read_registry, write_registry, read_repository, write_repository
* @var int $access_level the access level: 10 (Guest), 20 (Reporter), 30 (Developer), 40 (Maintainer), 50 (Owner)
* @var \DateTimeInterface $expires_at the token expires at midnight UTC on that date
* }
*
Expand Down Expand Up @@ -1500,11 +1499,6 @@ public function createProjectAccessToken($project_id, array $parameters = [])
})
;

$resolver->setDefined('access_level')
->setAllowedTypes('access_level', 'int')
->setAllowedValues('access_level', [10, 20, 30, 40, 50])
;

$resolver->setDefined('expires_at')
->setAllowedTypes('expires_at', \DateTimeInterface::class)
->setNormalizer('expires_at', $datetimeNormalizer)
Expand Down
1 change: 0 additions & 1 deletion tests/Api/ProjectsTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -2735,7 +2735,6 @@ public function shouldCreateProjectAccessToken(): void
'api',
'read_repository',
],
'access_level' => 30,
'expires_at' => '2021-01-31',
]
)
Expand Down

0 comments on commit c41ba94

Please sign in to comment.