Skip to content

Commit

Permalink
fix(Addressbook/js): validate string in preferred address renderrer
Browse files Browse the repository at this point in the history
  • Loading branch information
ccheng-dev committed Jun 13, 2024
1 parent 3a6d3f0 commit 5d1c4c2
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions tine20/Addressbook/js/ContactGrid.js
Original file line number Diff line number Diff line change
Expand Up @@ -231,12 +231,11 @@ Tine.Addressbook.ContactGridPanel.countryRenderer = function(data) {
* @return {*}
*/
Tine.Addressbook.ContactGridPanel.preferredAddressRenderer = function(value) {
var i18n = Tine.Tinebase.appMgr.get('Addressbook').i18n;

const i18n = Tine.Tinebase.appMgr.get('Addressbook').i18n;
switch (value) {
case '0':
case 'adr_one':
return i18n._('Business');
case '1':
case 'adr_two':
return i18n._('Private');
default:
return i18n._('Not set');
Expand Down

0 comments on commit 5d1c4c2

Please sign in to comment.