From aa7d06a277dfd5bbcdea7c60c8fc0339db63bbc3 Mon Sep 17 00:00:00 2001 From: Seyi Adebajo Date: Fri, 19 May 2017 11:57:46 -0700 Subject: [PATCH] fixes issue with updating field logical type on compliance --- wherehows-web/app/components/dataset-compliance.js | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/wherehows-web/app/components/dataset-compliance.js b/wherehows-web/app/components/dataset-compliance.js index be489a2a96..31891c3754 100644 --- a/wherehows-web/app/components/dataset-compliance.js +++ b/wherehows-web/app/components/dataset-compliance.js @@ -227,9 +227,7 @@ export default Component.extend({ */ const getAttributeOnField = (attribute, fieldName) => { const complianceEntities = get(this, policyComplianceEntitiesKey) || []; - const sourceField = complianceEntities.find( - ({ identifierField }) => identifierField === fieldName - ); + const sourceField = complianceEntities.find(({ identifierField }) => identifierField === fieldName); return sourceField ? sourceField[attribute] : null; }; @@ -403,10 +401,10 @@ export default Component.extend({ }, { value: fieldIdentifierTypes.none.value } ); + } else { + set(sourceIdentifierField, 'logicalType', logicalType); } - set(sourceIdentifierField, 'logicalType', logicalType); - return this.setDefaultClassification({ identifierField }, { value: logicalType }); },