Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Suppressing the getName() which is deprecated #1115

Closed
wants to merge 1 commit into from
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion modules/apigee_edge_teams/src/TeamPermissionHandler.php
Original file line number Diff line number Diff line change
Expand Up @@ -299,7 +299,8 @@ protected function sortPermissions(array $all_permissions = []) {
protected function getModuleNames(): array {
$modules = [];
foreach (array_keys($this->moduleHandler->getModuleList()) as $module) {
$modules[$module] = $this->moduleHandler->getName($module);
// @todo getName() is deprecated for Drupal 10.3 & is removed from drupal:12.0. Use \Drupal::service('extension.list.module')->getName($module) instead. https://www.drupal.org/node/3310017
$modules[$module] = $this->moduleHandler->getName($module); // @phpstan-ignore argument.type
}
asort($modules);
return $modules;
Expand Down
Loading