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

[6.x] Fix database url parsing for connections with no database specified #31185

merged 2 commits into from Jan 21, 2020


Copy link

danieloliveira079 commented Jan 21, 2020

This PR fixes how a database URL is parsed when the URL does not specify the database bit but ends with an /.

For example:

Before this fix the results from getDatabase($url) would be path=/. Consequently, affecting how arrays are filtered on RedisManager.php

A test case has been added to cover this scenario.

This REDIS_URL format is very similar to what you can find when running applications on Heroku apart the addition of the / at the very end. Without this properly fixed, application developers will have to implement workarounds within the code base of their projects.

@taylorotwell taylorotwell merged commit 4f87b37 into laravel:6.x Jan 21, 2020
2 checks passed
2 checks passed
continuous-integration/styleci/pr The analysis has passed
continuous-integration/travis-ci/pr The Travis CI build passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
None yet
Linked issues

Successfully merging this pull request may close these issues.

None yet

2 participants
You can’t perform that action at this time.