Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

AsyncException npsp.USER_UserService.handleDeactivatedSysAdminFuture(Set<Id>) #7262

Open
davidchengIC opened this issue Nov 6, 2024 · 0 comments

Comments

@davidchengIC
Copy link

davidchengIC commented Nov 6, 2024

Posting this for reference.

If a batch Apex process like DLRS updates an inactive sys admin user, NPSP will try to update the Error Settings custom settings by a future method, and that throws an error System.AsyncException: Future method cannot be called from a future or batch method: npsp.USER_UserService.handleDeactivatedSysAdminFuture(Set)

Workaround is to remove all the following permissions from inactive sys admin users:

  • Customize Application
  • Modify All Data
  • Author Apex

The problem is that the method is being called by the trigger when any field is updated, and it doesn't distinguish that a user is already inactive.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant