diff --git a/components/productArea/productAreaLinks.tsx b/components/productArea/productAreaLinks.tsx
index 61de2c31..56d074b7 100644
--- a/components/productArea/productAreaLinks.tsx
+++ b/components/productArea/productAreaLinks.tsx
@@ -6,11 +6,11 @@ const ProductAreaHasItems = (p: any)=> !!p?.teams.filter((it: any)=> it.dataprod
const ProductAreaLinks = () => {
var defaultProductAreaID = '6b149078-927b-4570-a1ce-97bbb9499fb6'
- const {productAreas} = useGetProductAreas()
+ const {productAreas, error} = useGetProductAreas()
const productAreaWithItems = productAreas?.filter(it=> ProductAreaHasItems(it));
if(productAreaWithItems.length>0){
defaultProductAreaID = productAreaWithItems.find(it=> it.id== defaultProductAreaID)?.id || productAreaWithItems[0].id
- }else{
+ }else if(error){
return null
}
diff --git a/pages/dataproduct/new.tsx b/pages/dataproduct/new.tsx
index 9215a837..80147628 100644
--- a/pages/dataproduct/new.tsx
+++ b/pages/dataproduct/new.tsx
@@ -8,10 +8,15 @@ import {
import { GetServerSideProps } from 'next'
import { addApolloState, initializeApollo } from '../../lib/apollo'
import InnerContainer from '../../components/lib/innerContainer'
+import LoaderSpinner from '../../components/lib/spinner'
const NewDataproduct = () => {
const userInfo = useUserInfoDetailsQuery()
+ if(!userInfo || userInfo.loading){
+ return