Universal Containers (UC) has a custom Apex class that enforces a business process and updates opportunities. UC has noticed that fields with field-level security permission of read only on certain users’ profiles are being updates by this class. How should the architect fix this problem?
A. Use the WITH SECURITY_ENFORCED keyword in the SOQL statement.
B. Put the code in an inner class that uses the With Sharing keyword.
C. Use the ISUpdatetable() Apex method to test each field prior to allowing update.
D. Add With Sharing keyword to the class.
Suggest answer: A
Reference:
No comments:
Please share to make the community better.