StanfordSpezi / SpeziFirebase

Google Firebase Spezi Modules
https://swiftpackageindex.com/StanfordSpezi/SpeziFirebase/documentation/
MIT License
4 stars 2 forks source link

Ensure name is updated after anonymous account linking #36

Closed Supereg closed 4 months ago

Supereg commented 4 months ago

Ensure name is updated after anonymous account linking

:recycle: Current situation & Problem

As described in #35, the displayName is not updated in the signup code path that handles linking signup credentials with an existing anonymous account. This PR fixes this issue by updating the display name of the anonymous account if the signup request provides a display name.

:gear: Release Notes

:books: Documentation

--

:white_check_mark: Testing

A regression test was added that verifies this behavior.

:pencil: Code of Conduct & Contributing Guidelines

By submitting creating this pull request, you agree to follow our Code of Conduct and Contributing Guidelines:

codecov[bot] commented 4 months ago

Codecov Report

All modified and coverable lines are covered by tests :white_check_mark:

Project coverage is 61.39%. Comparing base (f05c859) to head (5618c81).

Additional details and impacted files [![Impacted file tree graph](https://app.codecov.io/gh/StanfordSpezi/SpeziFirebase/pull/36/graphs/tree.svg?width=650&height=150&src=pr&token=Z84BufPFgU&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=StanfordSpezi)](https://app.codecov.io/gh/StanfordSpezi/SpeziFirebase/pull/36?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=StanfordSpezi) ```diff @@ Coverage Diff @@ ## main #36 +/- ## ========================================== + Coverage 60.21% 61.39% +1.18% ========================================== Files 19 19 Lines 1151 1155 +4 ========================================== + Hits 693 709 +16 + Misses 458 446 -12 ``` | [Files](https://app.codecov.io/gh/StanfordSpezi/SpeziFirebase/pull/36?dropdown=coverage&src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=StanfordSpezi) | Coverage Δ | | |---|---|---| | [...ount/Account Services/FirebaseAccountService.swift](https://app.codecov.io/gh/StanfordSpezi/SpeziFirebase/pull/36?src=pr&el=tree&filepath=Sources%2FSpeziFirebaseAccount%2FAccount+Services%2FFirebaseAccountService.swift&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=StanfordSpezi#diff-U291cmNlcy9TcGV6aUZpcmViYXNlQWNjb3VudC9BY2NvdW50IFNlcnZpY2VzL0ZpcmViYXNlQWNjb3VudFNlcnZpY2Uuc3dpZnQ=) | `77.39% <100.00%> (+0.84%)` | :arrow_up: | | [...Services/FirebaseEmailPasswordAccountService.swift](https://app.codecov.io/gh/StanfordSpezi/SpeziFirebase/pull/36?src=pr&el=tree&filepath=Sources%2FSpeziFirebaseAccount%2FAccount+Services%2FFirebaseEmailPasswordAccountService.swift&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=StanfordSpezi#diff-U291cmNlcy9TcGV6aUZpcmViYXNlQWNjb3VudC9BY2NvdW50IFNlcnZpY2VzL0ZpcmViYXNlRW1haWxQYXNzd29yZEFjY291bnRTZXJ2aWNlLnN3aWZ0) | `92.38% <100.00%> (+6.05%)` | :arrow_up: | ... and [1 file with indirect coverage changes](https://app.codecov.io/gh/StanfordSpezi/SpeziFirebase/pull/36/indirect-changes?src=pr&el=tree-more&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=StanfordSpezi) ------ [Continue to review full report in Codecov by Sentry](https://app.codecov.io/gh/StanfordSpezi/SpeziFirebase/pull/36?dropdown=coverage&src=pr&el=continue&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=StanfordSpezi). > **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=StanfordSpezi) > `Δ = absolute (impact)`, `ø = not affected`, `? = missing data` > Powered by [Codecov](https://app.codecov.io/gh/StanfordSpezi/SpeziFirebase/pull/36?dropdown=coverage&src=pr&el=footer&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=StanfordSpezi). Last update [f05c859...5618c81](https://app.codecov.io/gh/StanfordSpezi/SpeziFirebase/pull/36?dropdown=coverage&src=pr&el=lastupdated&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=StanfordSpezi). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=StanfordSpezi).