From 8a2bf8c1fc993f0d712d281f1cc2bed7867736e5 Mon Sep 17 00:00:00 2001 From: Alex Corey Date: Wed, 19 Aug 2020 12:18:04 -0400 Subject: [PATCH 1/2] adds fix to allow look up to fetch data --- awx/ui_next/src/components/Lookup/CredentialLookup.jsx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/awx/ui_next/src/components/Lookup/CredentialLookup.jsx b/awx/ui_next/src/components/Lookup/CredentialLookup.jsx index da62a053cef9..22f7dc54a639 100644 --- a/awx/ui_next/src/components/Lookup/CredentialLookup.jsx +++ b/awx/ui_next/src/components/Lookup/CredentialLookup.jsx @@ -68,8 +68,8 @@ function CredentialLookup({ actionsResponse?.data?.related_search_fields || [] ).map(val => val.slice(0, -8)), searchableKeys: Object.keys( - actionsResponse.data.actions?.GET || {} - ).filter(key => actionsResponse.data.actions?.GET[key].filterable), + actionsResponse.data?.actions?.GET || {} + ).filter(key => actionsResponse.data?.actions?.GET[key].filterable), }; }, [ credentialTypeId, From 7bff11379c55e0d027772a95b7fb7a64a877df4c Mon Sep 17 00:00:00 2001 From: Alex Corey Date: Wed, 19 Aug 2020 13:32:48 -0400 Subject: [PATCH 2/2] Update awx/ui_next/src/components/Lookup/CredentialLookup.jsx Co-authored-by: Jake McDermott --- awx/ui_next/src/components/Lookup/CredentialLookup.jsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/awx/ui_next/src/components/Lookup/CredentialLookup.jsx b/awx/ui_next/src/components/Lookup/CredentialLookup.jsx index 22f7dc54a639..c67e0087c60a 100644 --- a/awx/ui_next/src/components/Lookup/CredentialLookup.jsx +++ b/awx/ui_next/src/components/Lookup/CredentialLookup.jsx @@ -69,7 +69,7 @@ function CredentialLookup({ ).map(val => val.slice(0, -8)), searchableKeys: Object.keys( actionsResponse.data?.actions?.GET || {} - ).filter(key => actionsResponse.data?.actions?.GET[key].filterable), + ).filter(key => actionsResponse.data?.actions?.GET[key]?.filterable), }; }, [ credentialTypeId,