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

Fix saving preferences while AI API key is empty #11661

Merged
merged 2 commits into from
Aug 21, 2024
Merged

Conversation

InAnYan
Copy link
Collaborator

@InAnYan InAnYan commented Aug 21, 2024

Closes https://github.com/JabRef/jabref-issue-melting-pot/issues/511.

When you accept privacy policy for AI, AI features are enabled, but API key is empty.

If in this state you go to preferences, change some other preferences that you need (for example switching language), then preferences window won't allow this to do, because there is an empty API key.

What this PR does: even if API key is empty, we allow to save it empty. All logic will work okay after that, because empty API key is handled there, and as a last resort there

Mandatory checks

- [ ] Change in CHANGELOG.md described in a way that is understandable for the average user (if applicable)
- [ ] Tests created for changes (if applicable)

Copy link
Member

@koppor koppor left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code reads good. Kind of hot fix, just merging.

@koppor koppor added this pull request to the merge queue Aug 21, 2024
Merged via the queue into JabRef:main with commit 1d47410 Aug 21, 2024
21 checks passed
@koppor koppor deleted the fix-ai-api branch August 21, 2024 10:27
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.

2 participants