1

I'm trying to use the WireService to get fields for the current logged in user on a community/experience-site however the values for the fields I require are returning null. As you can see from the JSON contents returned from the WireService the fields do contain Email, Username, and Name (the fields I require) however no values are being returned. Do you know why the System fields are rendering values while specified fields are returning as blank? I wondered could it FLS on the User object but no FLS is available for the profile on standard fields.

Any tips on this would be appreciated. Thanks for your help.

{
    "apiName": "User",
    "childRelationships": {},
    "fields": {
        "Email": {
            "displayValue": null,
            "value": null
        },
        "Name": {
            "displayValue": null,
            "value": "Read Only"
        },
        "Username": {
            "displayValue": null,
            "value": null
        }
    },
    "id": "0051700000AlCjRAAV",
    "lastModifiedById": "0051700000Al0gdAAB",
    "lastModifiedDate": "2021-10-20T10:56:23.000Z",
    "recordTypeId": null,
    "recordTypeInfo": null,
    "systemModstamp": "2021-10-20T10:56:36.000Z"
}

1 Answer 1

1

Looks like this is because of the setting "Manage Personal User Information Visibility for External Users"

You can read more about this feature here.

  1. From Setup, in the Quick Find box, enter User Management Settings and then select User Management Settings.

  2. Disable Hide Personal Information if it’s enabled.

  3. Enable Enhanced Personal Information Management. Review the list of user fields classified as personal information that are concealed from external users.

1
  • Thank you. That is exactly the cause. I tried it out and the values have started to come through now after applying the settings change. I'll ask my team if they are ok with this or if I'll need a different approach but it's good to know the route cause. I was unsure why the values were being hidden. Thanks again.
    – RedQueries
    Oct 26, 2021 at 5:14

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .