[PR #1740] [MERGED] Fix Account Switching crash on log out #44689

Closed
opened 2026-04-26 11:55:20 -05:00 by GiteaMirror · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/bitwarden/android/pull/1740
Author: @fedemkr
Created: 1/31/2022
Status: Merged
Merged: 1/31/2022
Merged by: @mpbw2

Base: accountswitchingHead: accountswitching-fix-crash-log-out


📝 Commits (1)

  • fdbf94d Fix crash on account switching when logging out when having more than user at a time

📊 Changes

2 files changed (+11 additions, -3 deletions)

View changed files

📝 src/App/Controls/ExtendedToolbarItem.cs (+0 -2)
📝 src/iOS.Core/Renderers/CustomNavigationRenderer.cs (+11 -1)

📄 Description

Type of change

  • Bug fix
  • New feature development
  • Tech debt (refactoring, code cleanup, dependency upgrades, etc)
  • Build/deploy pipeline (DevOps)
  • Other

Objective

Fix crash when having two or more users and one of them logs out on Account Switching.

Code changes

  • CustomNavigationRenderer.cs: Added try....catch of the ObjectDisposedException given that we don't have a clearer way to check whether the Toolbar item has been disposed or change the approach on (un)subscription for the PropertyChanged

Testing requirements

The app shouldn't crash when logging out a user

Before you submit

  • I have added unit tests where it makes sense to do so (encouraged but not required)
  • This change requires a documentation update (notify the documentation team)
  • This change has particular deployment requirements (notify the DevOps team)

🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/bitwarden/android/pull/1740 **Author:** [@fedemkr](https://github.com/fedemkr) **Created:** 1/31/2022 **Status:** ✅ Merged **Merged:** 1/31/2022 **Merged by:** [@mpbw2](https://github.com/mpbw2) **Base:** `accountswitching` ← **Head:** `accountswitching-fix-crash-log-out` --- ### 📝 Commits (1) - [`fdbf94d`](https://github.com/bitwarden/android/commit/fdbf94d9ffd92ba2049ec72e7e6c80a0500320c8) Fix crash on account switching when logging out when having more than user at a time ### 📊 Changes **2 files changed** (+11 additions, -3 deletions) <details> <summary>View changed files</summary> 📝 `src/App/Controls/ExtendedToolbarItem.cs` (+0 -2) 📝 `src/iOS.Core/Renderers/CustomNavigationRenderer.cs` (+11 -1) </details> ### 📄 Description ## Type of change - [X] Bug fix - [X] New feature development - [ ] Tech debt (refactoring, code cleanup, dependency upgrades, etc) - [ ] Build/deploy pipeline (DevOps) - [ ] Other ## Objective <!--Describe what the purpose of this PR is. For example: what bug you're fixing or what new feature you're adding--> Fix crash when having two or more users and one of them logs out on Account Switching. ## Code changes <!--Explain the changes you've made to each file or major component. This should help the reviewer understand your changes--> <!--Also refer to any related changes or PRs in other repositories--> * **CustomNavigationRenderer.cs:** Added try....catch of the `ObjectDisposedException` given that we don't have a clearer way to check whether the Toolbar item has been disposed or change the approach on (un)subscription for the `PropertyChanged` ## Testing requirements <!--What functionality requires testing by QA? This includes testing new behavior and regression testing--> The app shouldn't crash when logging out a user ## Before you submit - [ ] I have added **unit tests** where it makes sense to do so (encouraged but not required) - [ ] This change requires a **documentation update** (notify the documentation team) - [ ] This change has particular **deployment requirements** (notify the DevOps team) --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
GiteaMirror added the pull-request label 2026-04-26 11:55:20 -05:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/android#44689