TransWikia.com

Guest users are unable to upload a file in a community

Salesforce Asked by Dan Beer on October 3, 2021

We have a community which has a lightning:fileUpload component for guests to upload anonymous file attachments.

At the point of creation the attachments have no parent and are assigned to the default owner for the community. Replication details as follows:

  1. Have the following settings configured:

    • Setup -> Salesforce Files -> General Settings -> "Allow site guest users to upload files" = enable
    • Have a LEX community with Builder -> Settings -> General -> Public Access -> "Public can access the community" = enabled
    • Community Preferences -> Let guest users see other members of this community = disabled
    • Setup > Communities Settings > "Reassign new records created by guest users to the default owner" = enabled
    • Community guest user profile -> ‘View All Users’ = disabled
  2. Create a lightning component to upload file as below and place it in
    an object that guest user can access.

  3. Go to the community page with guest user context and upload a file.

  4. Observe error ‘Can’t upload file’ and file is not uploaded.

This is exactly what is reportedly fixed here: https://trailblazer.salesforce.com/issues_view?id=a1p3A000001YnzNQAS&title=guest-users-are-unable-to-upload-a-file-in-a-community-when-reassign-new-records-created-by-guest-users-to-the-default-owner-is-enabled-for-contentv

If I disabled "Reassign new records created by guest users to the default owner" it works fine.

Also, have tried this: https://releasenotes.docs.salesforce.com/en-us/summer20/release-notes/rn_networks_guest_file_upload.htm

Has anyone seen this?

One Answer

Do you have the "Allow site guest users to upload files" checkbox checked? If not, you can go to Quick Find > General Settings > Allow site guest users to upload files (check it). You need to activate the Sites domain too, you can find it on Quick Find > Sites and do the setup. I hope this helps!

I'll leave a link to the documentation: https://trailblazer.salesforce.com/issues_view?id=a1p3A000001YpGnQAK

Answered by Samuel Castillo on October 3, 2021

Add your own answers!

Ask a Question

Get help from others!

© 2024 TransWikia.com. All rights reserved. Sites we Love: PCI Database, UKBizDB, Menu Kuliner, Sharing RPP