Bugfix: Google Drive API about() set storageQuota field#111
Conversation
As documented in https://developers.google.com/drive/api/reference/rest/v3/about/get, the fields parameter is required, hence setting fields = storageQuota for quota query to succeed. Signed-off-by: Raymond Lai <airwave209gt@gmail.com>
|
Thanks so much, @TranceLove! Would you mind signing your commit? You can follow [these instructions](https://docs.github.com/en/authentication/managing-commit-signature-verification/signing-commits) if needed. Also, I've added a few suggestions below from Copilot — feel free to take a look. One quick thought: do you think this feature should be surfaced in the sample app? Totally okay if you can't take it on right now, but if you think it's worth including, would you mind opening a tech debt issue so we can track it for later? Appreciate your help! 🙌 CC - @itsme291 (Saurabh) |
There was a problem hiding this comment.
Copilot reviewed 7 out of 7 changed files in this pull request and generated no comments.
Comments suppressed due to low confidence (1)
packages/plugin-googledrive-non-gms/src/test/java/com/openmobilehub/android/storage/plugin/googledrive/nongms/data/repository/NonGmsFileRepositoryTest.kt:1047
- [nitpick] For consistency with the repository code, consider referencing the STORAGE_QUOTA constant defined in NonGmsFileRepository.kt rather than using the literal "storageQuota" string in tests.
googleStorageApiService.about("storageQuota")
Made STORAGE_QUOTA @VisibleForTesting so tests can take reference to. Signed-off-by: Raymond Lai <airwave209gt@gmail.com>
Summary
As documented in https://developers.google.com/drive/api/reference/rest/v3/about/get, the fields parameter is required, hence setting fields = storageQuota for quota query to succeed.
Demo
Changes is internal, hence should not affect display to end user at sample app.
Checklist: