A custom button in a managed package uses a protected custom setting in the same package to retrieve a namespace:
When installed with namespace PKG, this looks like
This used to work in both classic and lightning before Spring 2020. With Spring 2020, it instead produces an error message:
Page PageName does not exist
When logging in through subscribers access, the button correctly redirects to the appropriate page. A Base64 decode reveals
When logged in directly, the redirect drops the namespace and instead goes to:
It also works well when another managed package "PKG2" has a protected custom setting and a button used for the same purpose, targeting the page from package "PKG".
The only scenario where it does not seem to work is when the button, the custom setting and the target page are in the same "PKG" managed package.
I thought it may be related to Require Customize Application Permission for Direct Read Access to Custom Metadata Types or Require Customize Application Permission for Direct Read Access to Custom Settings critical update, so I tried turning the following options off in
- Restrict access to custom settings
- Restrict access to custom metadata types
I've also confirmed that the profile has the following permissions:
- Customize Application
- View All Custom Settings
What else can I try?