-
Notifications
You must be signed in to change notification settings - Fork 6
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: changing profile avatar doesn't reflect update (WPB-5494) #2443
fix: changing profile avatar doesn't reflect update (WPB-5494) #2443
Conversation
Datadog ReportAll test runs ✅ 2 Total Test Services: 0 Failed, 2 Passed Test Services
|
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## release/candidate #2443 +/- ##
====================================================
Coverage ? 58.29%
Complexity ? 21
====================================================
Files ? 1166
Lines ? 45024
Branches ? 4234
====================================================
Hits ? 26246
Misses ? 16894
Partials ? 1884 Continue to review full report in Codecov by Sentry.
|
* fix: remove SELECT changes from updateUser query * fix: add transactionWithResult when updateUser and return select changes * test: add tests for observing user details by id
* fix: changing profile avatar doesn't reflect update (WPB-5494) (#2443) * fix: remove SELECT changes from updateUser query * fix: add transactionWithResult when updateUser and return select changes * test: add tests for observing user details by id * fix: add UPDATE OR FAIL to update query and remove select changes query as it is not used anymore * fix: remove unused select changes query and change return type of updateUser to Unit * fix: adjust existing tests --------- Co-authored-by: Alexandre Ferris <[email protected]>
* fix: changing profile avatar doesn't reflect update (WPB-5494) (#2443) * fix: remove SELECT changes from updateUser query * fix: add transactionWithResult when updateUser and return select changes * test: add tests for observing user details by id * fix: add UPDATE OR FAIL to update query and remove select changes query as it is not used anymore * fix: remove unused select changes query and change return type of updateUser to Unit * fix: adjust existing tests --------- Co-authored-by: Alexandre Ferris <[email protected]>
PR Submission Checklist for internal contributors
The PR Title
SQPIT-764
The PR Description
What's new in this PR?
Issues
When changing user profile avatar it wasn't being reflected in other screens in the app
Causes (Optional)
the query
updateUser
was a transaction returningSELECT changes()
, thus sqldelight not emitting the update on the table.Solutions
Remove transaction and
SELECT changes()
from the query and addtransactionWithResult
on the DAOImpl to properly reflect the changes upwards when needed.Testing
How to Test
Notes (Optional)
@vitorhugods opened an issue on SQLDelight : sqldelight/sqldelight#5001