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

Refactor: Remove Console Log and Enhance DatabaseURL Configuration - Fixes#998 #1001

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

karthxk07
Copy link

Description

In this pull request, I removed the console.log(country) line for improved code cleanliness. Additionally, I edited the databaseURL property in the configuration to use the import.meta.env.VITE_APP_DATABASE_URL variable instead of constructing the URL inline. The updated line now reads:

databaseURL: import.meta.env.VITE_APP_DATABASE_URL,

Related Issue

Fixes #998

Motivation and Context

The removal of console.log(country) enhances the codebase by eliminating unnecessary logging. The modification to the databaseURL property allows for more flexibility and maintainability by utilizing an environment variable (VITE_APP_DATABASE_URL) instead of hardcoding the URL. (Earlier it was hardcoded to only work for databases in US central region 'https://DATABASE_NAME.firebaseio.com')

How Has This Been Tested?
I have tested these changes in a local development environment. Specifically, I performed the following tests:

Checked that the console.log(country) line was successfully removed without affecting the functionality.
Verified that the updated databaseURL configuration works correctly with the specified environment variable.

Screenshots or GIF (In Case of UI Changes):
Screencast from 2024-01-01 14-05-45.webm

Types of Changes

[x] Bug fix (non-breaking change which fixes an issue)
[ ] New feature (non-breaking change which adds functionality)
[ ] Breaking change (fix or feature that would cause existing functionality to change)
[x] Other (please specify): Code cleanup and configuration enhancement
Checklist:

[x] My code follows the code style of this project.
[ ] My change requires a change to the documentation.
[ ] I have updated the documentation accordingly.
[ ] I have added tests to cover my changes.
[x] All new and existing tests passed.

@karthxk07 karthxk07 changed the title Fixes#998 Refactor: Remove Console Log and Enhance DatabaseURL Configuration - Fixes#998 Jan 1, 2024
@karthxk07
Copy link
Author

@Maahi10001 @ABHISHEK-PANDEY2 can i get this reviewed, please?

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.

User Creation Fails Without Firebase Emulators Setup; Country Value Logging on Every Change
1 participant