Skip to content

Conversation

@rmohan20
Copy link
Contributor

@rmohan20 rmohan20 commented Jul 22, 2022

  1. Fixed the new unresolved violation message.
  2. Modified other messages while trying to follow the standards.
  3. Handling UserActionException so that they don't show up with a long stacktrace.

@rmohan20 rmohan20 requested a review from jfeingold35 July 22, 2022 17:23
public static final String UNRESOLVED_CRUD_FLS_TEMPLATE =
"SFGE was unable to resolve the parameter passed to [%2$s] operation. "
+ "Ensure manually that this operation has the necessary CRUD/FLS checks.";
"SFGE couldn't resolve the parameter passed to [%2$s] operation%4$s. "
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@jfeingold35 I've changed the format based on our conversation.

flsViolationInfo.getValidationType().name(),
flsViolationInfo.getObjectName());
flsViolationInfo.getObjectName(),
fieldInformation);
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Now passing in fieldInformation as another parameter.

message,
equalToIgnoringCase(
"FLS validation is missing for [UPDATE] operation on [My_Obj__c] with field(s) [Name,Status__c] - SFGE may not have parsed some objects/fields correctly. Please confirm if the objects/fields involved in these segments have FLS checks: [Relational_Field__r.Another_field__c]"));
String.format(
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Modified failing tests to use String formats instead of hardcoding the message. Will clean up the remaining tests at another iteration while applying Teresa's feedback.

@rmohan20 rmohan20 merged commit 5e22b58 into dev-3 Jul 22, 2022
@stephen-carter-at-sf stephen-carter-at-sf deleted the rm/unresolved-violation-msg-fix branch May 17, 2024 14:30
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

Successfully merging this pull request may close these issues.

3 participants