[PM-32743] Convert collections to folders when importing into My Items#20453
[PM-32743] Convert collections to folders when importing into My Items#20453mcamirault wants to merge 3 commits intomainfrom
Conversation
🤖 Bitwarden Claude Code ReviewOverall Assessment: APPROVE Re-review after the fix-up commits ( Code Review DetailsNo findings. |
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #20453 +/- ##
==========================================
+ Coverage 47.11% 47.13% +0.01%
==========================================
Files 3943 3947 +4
Lines 119797 119862 +65
Branches 18388 18396 +8
==========================================
+ Hits 56442 56492 +50
- Misses 59081 59091 +10
- Partials 4274 4279 +5 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
harr1424
left a comment
There was a problem hiding this comment.
Barring the ❌ CRITICAL finding reported during the Claude review, this looks good to me! Happy to re-review if it's not a false positive.
|
❌ The last analysis has failed. |
|
@claude Review this again |
|
Claude finished @mcamirault's task in 2m 10s —— View job Re-review: APPROVEThe previously flagged CRITICAL issue is resolved. The multi-collection guard at What was verified this pass:
Non-blocking observations:
No new findings. Approving. |
🎟️ Tracking
https://bitwarden.atlassian.net/browse/PM-32743
📔 Objective
This PR changes what happens to collections when importing into My Items. Previously other collections a cipher might be part of were ignored because My Items does not support nesting; with this change the other collections will be recreated as folders with the same names, with any collection hierarchy recreated as a folder hierarchy and with the cipher in the folder created from its collection. Since a cipher can only have one folder but be part of multiple collections, we now throw an error if you try to import into My Items with any ciphers that are part of multiple collections. Importing into the base of the org or into any other collection besides My Items is unchanged.
📸 Screenshots
For the following demos we are importing from an org export with three collections and two ciphers:
Default Collection: One cipher called "Default Collection Credential"
Developers: No ciphers, one sub-collection called "Tools Developers"
Tools Developers: One cipher called "Tools Dev Credentials"
Importing into the base of an empty organization. This is will also happen if importing into any collection besides My Items, though the collection structure will be under the target collection
Screen.Recording.2026-04-30.at.11.54.54.mov
This results in the following collection structure:
and no folders are created
Importing into My Items
Screen.Recording.2026-04-30.at.11.55.46.mov
This results in the following collection structure:
and the following folder structure: