diff --git a/force-app/main/default/classes/HH_Container_LCTRL.cls b/force-app/main/default/classes/HH_Container_LCTRL.cls index 6cb5e690791..d3d6fba3a7f 100644 --- a/force-app/main/default/classes/HH_Container_LCTRL.cls +++ b/force-app/main/default/classes/HH_Container_LCTRL.cls @@ -551,21 +551,12 @@ public with sharing class HH_Container_LCTRL { } Set addressFields = new Set{ - 'Default_Address__c', - 'Household_Account__c', - 'Address_Type__c', 'MailingStreet__c', 'MailingStreet2__c', 'MailingCity__c', 'MailingState__c', 'MailingPostalCode__c', - 'MailingCountry__c', - 'Seasonal_Start_Month__c', - 'Seasonal_Start_Day__c', - 'Seasonal_End_Month__c', - 'Seasonal_End_Day__c', - 'Geolocation__Latitude__s', - 'Geolocation__Longitude__s' + 'MailingCountry__c' }; for (String addressField : addressFields) { diff --git a/force-app/main/default/classes/HH_ManageHH_CTRL.cls b/force-app/main/default/classes/HH_ManageHH_CTRL.cls index bf7d016d055..30e2edf3955 100644 --- a/force-app/main/default/classes/HH_ManageHH_CTRL.cls +++ b/force-app/main/default/classes/HH_ManageHH_CTRL.cls @@ -189,11 +189,12 @@ public with sharing class HH_ManageHH_CTRL { String accountToCheck = isHHAccount ? 'Account' : 'npo02__Household__c'; Set fieldsToCheck = new Set(); for (FieldSetMember fsMember : hhFieldSet) { + DescribeFieldResult dfr = fsMember.getSObjectField().getDescribe(); + if (dfr.isCalculated() || !dfr.permissionable || fsMember.getFieldPath().contains('__r')) { + continue; + } fieldsToCheck.add(fsMember.getFieldPath()); } - if (isHHAccount) { - fieldsToCheck.add('npo02__Household__c'); - } for (String fieldToCheck : fieldsToCheck) { if (!UTIL_Permissions.canUpdate(accountToCheck, fieldToCheck, false)) { return false;