[PM-36838] Render DeviceType display name in event integration templates#8011
[PM-36838] Render DeviceType display name in event integration templates#8011lastbestdev wants to merge 3 commits into
Conversation
The #DeviceType# integration template token resolved to the DeviceType enum member identifier (e.g. "ChromeExtension") because ReplaceTokens calls .ToString() on the value. Expose the [Display(Name)] value via GetDisplayName() so rendered event payloads show the friendly name (e.g. "Chrome Extension") instead.
🤖 Bitwarden Claude Code ReviewOverall Assessment: APPROVE Reviewed a focused bugfix that changes No security, correctness, breaking-change, or performance concerns were found. Code Review DetailsNo findings. The change is small, well-scoped, and appropriately tested for both the set and null device-type cases. |
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #8011 +/- ##
=======================================
Coverage 62.45% 62.46%
=======================================
Files 2293 2293
Lines 99797 99797
Branches 9007 9008 +1
=======================================
+ Hits 62330 62336 +6
+ Misses 35295 35288 -7
- Partials 2172 2173 +1 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
🎟️ Tracking
https://bitwarden.atlassian.net/browse/PM-36838
Relates to bitwarden/clients#21600
📔 Objective
The #DeviceType# integration template token resolved to the DeviceType enum member identifier (e.g. "ChromeExtension") because ReplaceTokens calls .ToString() on the value. Expose the [Display(Name)] value via GetDisplayName() so rendered event payloads show the friendly name (e.g. "Chrome Extension") instead.
📸 Screenshots
Event sent to Splunk (see "deviceName" value. "Chrome" is the display value for the "ChromeBrowser" device type enum member)