nerdexam
Salesforce

PDII · Question #203

Lightning Aura Component Lightning Aura Controller Apex Controller Given the code above, which two changes need to be made in the Apex Controller for the code to work? (Choose two.)

The correct answer is A. Remove line 06 from the Apex Controller and use firstName in the return C. Change the argument from JSONObject to String. See the full explanation below for the reasoning.

Question

Lightning Aura Component Lightning Aura Controller Apex Controller Given the code above, which two changes need to be made in the Apex Controller for the code to work? (Choose two.)

Options

  • ARemove line 06 from the Apex Controller and use firstName in the return
  • BChange the method signature to be global static, not public static
  • CChange the argument from JSONObject to String
  • DAnnotate the entire class as @AuraEnabled instead of just the single method

How the community answered

(44 responses)
  • A
    80% (35)
  • B
    7% (3)
  • D
    14% (6)

Community Discussion

No community discussion yet for this question.

Full PDII Practice