Skip to content

Fix OAuth admin groups not being stored - #203

Open
mandarl wants to merge 1 commit into
masterfrom
fix/oauth-admin-groups
Open

Fix OAuth admin groups not being stored#203
mandarl wants to merge 1 commit into
masterfrom
fix/oauth-admin-groups

Conversation

@mandarl

@mandarl mandarl commented Jan 24, 2026

Copy link
Copy Markdown
Member

Summary

Fix OAuth groups not being stored due to missing return statement in OpenIDConnectService::getGroupsFromUserInfo(). This prevented admin rights from being assigned correctly when logging in via OAuth.

Root Cause

The getGroupsFromUserInfo() method was building the $result array with extracted group names but never returning it, causing all OAuth user groups to be lost.

Changes

  • Added missing return $result; statement in src/Auth/OpenIDConnectService.php:101

Test Plan

  • Test OAuth login with an admin user account
  • Verify admin rights are properly assigned (Calendar Admins, Honorarium Admins, etc.)
  • Confirm admin menus and permissions appear correctly

The getGroupsFromUserInfo() method was building the groups array but never returning it, causing all OAuth user groups to be lost. This prevented admin rights from being assigned correctly.

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It looks like you committed it by mistake.

}
}
}
return $result;

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fix is correct. $result is built locally and populated in the loop , but never returned.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants