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

Api stateful domains config option #354

Merged
merged 2 commits into from
Apr 8, 2024

Conversation

gdebrauwer
Copy link
Contributor

In a project that runs on 2 domains, I had an issue where the log-viewer API calls failed and caused an 'this action is unauthorized' on the secondary domain. After some digging, I found that I needed to set the sanctum.stateful config option. The problem is that my project does not use Sanctum. I had to create a dummy sanctum.php config to create and set that config variable.

That's why I propose to make that an option in the log-viewer config so that it can be easily customized even when you don't use Sanctum in your project.

I made the change a non-breaking change by still checking and using config('sanctum.stateful') if the config('log-viewer.api_stateful_domains') is not set.

@gdebrauwer gdebrauwer changed the title Stateful domain config option Api stateful domains config option Mar 30, 2024
@arukompas arukompas merged commit 873ec61 into opcodesio:main Apr 8, 2024
21 checks passed
@arukompas
Copy link
Contributor

Big thanks @gdebrauwer , this makes perfect sense!

Tagged a new release - https://github.com/opcodesio/log-viewer/releases/tag/v3.7.0

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.

None yet

2 participants