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

Remove extra DB_DATABASE #287

Merged
merged 1 commit into from
Oct 5, 2023
Merged

Conversation

ConnySjoblom
Copy link
Contributor

When creating a new Laravel project using the installer, and selecting sqlite as database the .env file DB_DATABASE row ends up being commented out twice:

# DB_PORT=3306
# # DB_DATABASE=laravel
# DB_USERNAME=root

This PR fixes that by removing the extra line in $defaults

@crynobone
Copy link
Member

Where exactly does it cause # to be added twice?

@ConnySjoblom
Copy link
Contributor Author

ConnySjoblom commented Oct 4, 2023

Where exactly does it cause # to be added twice?

https://github.com/laravel/installer/blob/master/src/NewCommand.php#L262

It loops through all of the defaults, and prepends the #, and since DB_DATABASE is in $defaults twice, this happens.

@taylorotwell taylorotwell merged commit 04e1bbf into laravel:master Oct 5, 2023
7 checks passed
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.

4 participants