- 
                Notifications
    You must be signed in to change notification settings 
- Fork 4.1k
feat(firestore): add client language support for Firestore plugin on Android and iOS #17830
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
base: main
Are you sure you want to change the base?
Conversation
| Using Gemini Code AssistThe full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips. Invoking Gemini You can request assistance from Gemini at any point by creating a comment using either  
 Customization To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a  Limitations & Feedback Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for Github and other Google products, sign up here. | 
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Seems like fire/ will be double-included in API header as this PR stands, and just an understanding question (that is, I am likely misunderstanding something but want to understand...) on the RestrictedAPI lint suppression
        
          
                ...roid/src/main/java/io/flutter/plugins/firebase/firestore/FlutterFirebaseFirestorePlugin.java
              
                Outdated
          
            Show resolved
            Hide resolved
        
              
          
                ...roid/src/main/java/io/flutter/plugins/firebase/firestore/FlutterFirebaseFirestorePlugin.java
          
            Show resolved
            Hide resolved
        
              
          
                ...ore/cloud_firestore/ios/cloud_firestore/Sources/cloud_firestore/FLTFirebaseFirestorePlugin.m
              
                Outdated
          
            Show resolved
            Hide resolved
        
      There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM! I'm unable to resolve my threads but they're all resolved, from my perspective
🚂
Description
This PR adds support for setting the client language for Firestore on both Android and iOS. On Android, we rely on a restricted API since the FirebaseFirestore.setClientLanguage method is package-private. However, this method internally calls
FirestoreChannel.setClientLanguage, which is public (though marked as restricted). To use it safely, we suppress the lint warning with the@SuppressLintannotation.Related Issues
Fixes #17822
Checklist
Before you create this PR confirm that it meets all requirements listed below by checking the relevant checkboxes (
[x]).This will ensure a smooth and quick review process. Updating the
pubspec.yamland changelogs is not required.///).melos run analyze) does not report any problems on my PR.Breaking Change
Does your PR require plugin users to manually update their apps to accommodate your change?