[PR #5498] [MERGED] [PM-22399] Send 2FA email when view appears #5818

Closed
opened 2025-11-27 00:14:49 -06:00 by GiteaMirror · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/bitwarden/android/pull/5498
Author: @andrebispo5
Created: 7/9/2025
Status: Merged
Merged: 7/15/2025
Merged by: @andrebispo5

Base: mainHead: pm-22399/bug-2fa-email-not-sent


📝 Commits (6)

  • 542885c [PM-22399] Send email code on init if auth method is email and not device verification.
  • 38b1bbe [PM-22399] Remove suppression
  • acae31f [PM-22399] Apply PR suggestions
  • 334be7b [PM-22399] lint
  • 26bcf61 [PM-22399] Small test refactor
  • becf997 [PM-22399] Remove suppress

📊 Changes

2 files changed (+110 additions, -1 deletions)

View changed files

📝 app/src/main/kotlin/com/x8bit/bitwarden/ui/auth/feature/twofactorlogin/TwoFactorLoginViewModel.kt (+31 -1)
📝 app/src/test/kotlin/com/x8bit/bitwarden/ui/auth/feature/twofactorlogin/TwoFactorLoginViewModelTest.kt (+79 -0)

📄 Description

🎟️ Tracking

https://bitwarden.atlassian.net/browse/PM-22399

📔 Objective

Previously, the server was configured to send the 2FA email as part of login if email was the user's only 2FA option. This has since changed, and now the app needs to request this email be sent when the view appears. This only applies to 2FA, the device verification code email is still sent by the server.

📸 Screenshots

https://github.com/user-attachments/assets/3d365b8f-9c3a-4058-b624-23cb7e31de07

Reminders before review

  • Contributor guidelines followed
  • All formatters and local linters executed and passed
  • Written new unit and / or integration tests where applicable
  • Protected functional changes with optionality (feature flags)
  • Used internationalization (i18n) for all UI strings
  • CI builds passed
  • Communicated to DevOps any deployment requirements
  • Updated any necessary documentation (Confluence, contributing docs) or informed the documentation team

🦮 Reviewer guidelines

  • 👍 (:+1:) or similar for great changes
  • 📝 (:memo:) or ℹ️ (:information_source:) for notes or general info
  • (:question:) for questions
  • 🤔 (:thinking:) or 💭 (:thought_balloon:) for more open inquiry that's not quite a confirmed issue and could potentially benefit from discussion
  • 🎨 (:art:) for suggestions / improvements
  • (:x:) or ⚠️ (:warning:) for more significant problems or concerns needing attention
  • 🌱 (:seedling:) or ♻️ (:recycle:) for future improvements or indications of technical debt
  • ⛏ (:pick:) for minor or nitpick changes

🔄 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/5498 **Author:** [@andrebispo5](https://github.com/andrebispo5) **Created:** 7/9/2025 **Status:** ✅ Merged **Merged:** 7/15/2025 **Merged by:** [@andrebispo5](https://github.com/andrebispo5) **Base:** `main` ← **Head:** `pm-22399/bug-2fa-email-not-sent` --- ### 📝 Commits (6) - [`542885c`](https://github.com/bitwarden/android/commit/542885c26cd0ab6af8acd93eb33aa6b9919c2e7c) [PM-22399] Send email code on init if auth method is email and not device verification. - [`38b1bbe`](https://github.com/bitwarden/android/commit/38b1bbe30df6be2a3127155957c3865c4d23417e) [PM-22399] Remove suppression - [`acae31f`](https://github.com/bitwarden/android/commit/acae31fded3750cf517a7eef16dd7497c5c93f94) [PM-22399] Apply PR suggestions - [`334be7b`](https://github.com/bitwarden/android/commit/334be7b34ad90917463d1bdbc78067363baf0752) [PM-22399] lint - [`26bcf61`](https://github.com/bitwarden/android/commit/26bcf6193188b7bac2b8c3380ac7a520b21c6a99) [PM-22399] Small test refactor - [`becf997`](https://github.com/bitwarden/android/commit/becf997c1fa7866b17b42a0eb70c66af5fbb7474) [PM-22399] Remove suppress ### 📊 Changes **2 files changed** (+110 additions, -1 deletions) <details> <summary>View changed files</summary> 📝 `app/src/main/kotlin/com/x8bit/bitwarden/ui/auth/feature/twofactorlogin/TwoFactorLoginViewModel.kt` (+31 -1) 📝 `app/src/test/kotlin/com/x8bit/bitwarden/ui/auth/feature/twofactorlogin/TwoFactorLoginViewModelTest.kt` (+79 -0) </details> ### 📄 Description ## 🎟️ Tracking <!-- Paste the link to the Jira or GitHub issue or otherwise describe / point to where this change is coming from. --> https://bitwarden.atlassian.net/browse/PM-22399 ## 📔 Objective <!-- Describe what the purpose of this PR is, for example what bug you're fixing or new feature you're adding. --> Previously, the server was configured to send the 2FA email as part of login if email was the user's only 2FA option. This has since changed, and now the app needs to request this email be sent when the view appears. This only applies to 2FA, the device verification code email is still sent by the server. ## 📸 Screenshots <!-- Required for any UI changes; delete if not applicable. Use fixed width images for better display. --> https://github.com/user-attachments/assets/3d365b8f-9c3a-4058-b624-23cb7e31de07 ## ⏰ Reminders before review - Contributor guidelines followed - All formatters and local linters executed and passed - Written new unit and / or integration tests where applicable - Protected functional changes with optionality (feature flags) - Used internationalization (i18n) for all UI strings - CI builds passed - Communicated to DevOps any deployment requirements - Updated any necessary documentation (Confluence, contributing docs) or informed the documentation team ## 🦮 Reviewer guidelines <!-- Suggested interactions but feel free to use (or not) as you desire! --> - 👍 (`:+1:`) or similar for great changes - 📝 (`:memo:`) or ℹ️ (`:information_source:`) for notes or general info - ❓ (`:question:`) for questions - 🤔 (`:thinking:`) or 💭 (`:thought_balloon:`) for more open inquiry that's not quite a confirmed issue and could potentially benefit from discussion - 🎨 (`:art:`) for suggestions / improvements - ❌ (`:x:`) or ⚠️ (`:warning:`) for more significant problems or concerns needing attention - 🌱 (`:seedling:`) or ♻️ (`:recycle:`) for future improvements or indications of technical debt - ⛏ (`:pick:`) for minor or nitpick changes --- <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 2025-11-27 00:14:49 -06:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/android#5818