'Aura Component shows correctly in preview but not in real experience site

Im trying to display a field of the current ID and it works perfectly in experience site preview but doesnt render in the actual site.

<aura:if isTrue="{! not( empty( v.objId ) ) }">
 <lightning:recordViewForm recordId="{!v.objId}" objectApiName="customobj__c">
 <lightning:outputField fieldName="child__c" variant="label-hidden" class="custom"/>

Obj id is sent correctly in both cases, i have checked it in system debugger.



Solution 1:[1]

It was a profile issue. The account being used didn't have permissions to view the field.

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1 ouflak