Skip to content

Conversation

@Boy132
Copy link
Member

@Boy132 Boy132 commented Jan 26, 2026

Use getConfigKey in the default isEnabled and call isEnabled instead of manually checking the config key.

@Boy132 Boy132 self-assigned this Jan 26, 2026
@coderabbitai
Copy link

coderabbitai bot commented Jan 26, 2026

📝 Walkthrough

Walkthrough

OAuth configuration handling is refactored to consolidate state management by delegating to the OAuthSchema's isEnabled() method rather than directly reading environment variables in the Settings page. The schema's configuration key lookup is simplified by removing redundant local construction.

Changes

Cohort / File(s) Summary
OAuth Schema Configuration
app/Extensions/OAuth/Schemas/OAuthSchema.php, app/Filament/Admin/Pages/Settings.php
The isEnabled() method in OAuthSchema is simplified to delegate configuration lookups via getConfigKey(). The Settings page now uses the schema's isEnabled() state for controlling visibility and defaults instead of directly reading environment variables. Action IDs changed from generated uppercase IDs to $schema->getId(). Enable action enhanced with additional UI behaviors including modal headings, submit labels, and custom data-driven state updates.
🚥 Pre-merge checks | ✅ 2 | ❌ 1
❌ Failed checks (1 warning)
Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 33.33% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (2 passed)
Check name Status Explanation
Title check ✅ Passed The title accurately describes the main change: simplifying OAuth provider enabled checks by using getConfigKey() and relying on isEnabled() method.
Description check ✅ Passed The description clearly relates to the changeset by explaining the refactoring approach: delegating to getConfigKey() and calling isEnabled() instead of manual config checks.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.


Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@Boy132 Boy132 merged commit e14bb7d into main Jan 27, 2026
32 checks passed
@Boy132 Boy132 deleted the boy132/fix-oauth-enabled-check branch January 27, 2026 10:27
@github-actions github-actions bot locked and limited conversation to collaborators Jan 27, 2026
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants