@@ -119,9 +119,8 @@ public static ModelAndView home() {
119119 try {
120120 // <!-- ATTENTION: reCAPTCHA Example (Server Part 1/2) Starts -->
121121 assessmentResponse = CreateAssessment .createAssessment (
122- CONTEXT .get ("project_id" ),
123- CONTEXT .get ("site_key" ),
124- jsonData .get ("token" ));
122+ CONTEXT .get ("project_id" ), CONTEXT .get ("site_key" ),
123+ jsonData .get ("token" ), recaptchaAction );
125124
126125 // Check if the token is valid, score is above threshold score and the action equals expected.
127126 // Take action based on the result (BAD / NOT_BAD).
@@ -172,9 +171,8 @@ public static ModelAndView signup() {
172171 try {
173172 // <!-- ATTENTION: reCAPTCHA Example (Server Part 1/2) Starts -->
174173 assessmentResponse = CreateAssessment .createAssessment (
175- CONTEXT .get ("project_id" ),
176- CONTEXT .get ("site_key" ),
177- jsonData .get ("token" ).toString ());
174+ CONTEXT .get ("project_id" ), CONTEXT .get ("site_key" ),
175+ jsonData .get ("token" ).toString (), recaptchaAction );
178176
179177 // Check if the token is valid, score is above threshold score and the action equals expected.
180178 // Take action based on the result (BAD / NOT_BAD).
@@ -227,9 +225,8 @@ public static ModelAndView login() {
227225 try {
228226 // <!-- ATTENTION: reCAPTCHA Example (Server Part 1/2) Starts -->
229227 assessmentResponse = CreateAssessment .createAssessment (
230- CONTEXT .get ("project_id" ),
231- CONTEXT .get ("site_key" ),
232- jsonData .get ("token" ));
228+ CONTEXT .get ("project_id" ), CONTEXT .get ("site_key" ),
229+ jsonData .get ("token" ), recaptchaAction );
233230
234231 // Check if the token is valid, score is above threshold score and the action equals expected.
235232 // Take action based on the result (BAD / NOT_BAD).
@@ -282,9 +279,8 @@ public static ModelAndView store() {
282279 try {
283280 // <!-- ATTENTION: reCAPTCHA Example (Server Part 1/2) Starts -->
284281 assessmentResponse = CreateAssessment .createAssessment (
285- CONTEXT .get ("project_id" ),
286- CONTEXT .get ("site_key" ),
287- jsonData .get ("token" ).toString ());
282+ CONTEXT .get ("project_id" ), CONTEXT .get ("site_key" ),
283+ jsonData .get ("token" ).toString (), recaptchaAction );
288284
289285 // Check if the token is valid, score is above threshold score and the action equals expected.
290286 // Take action based on the result (BAD / NOT_BAD).
@@ -336,9 +332,8 @@ public static ModelAndView comment() {
336332 try {
337333 // <!-- ATTENTION: reCAPTCHA Example (Server Part 1/2) Starts -->
338334 assessmentResponse = CreateAssessment .createAssessment (
339- CONTEXT .get ("project_id" ),
340- CONTEXT .get ("site_key" ),
341- jsonData .get ("token" ));
335+ CONTEXT .get ("project_id" ), CONTEXT .get ("site_key" ),
336+ jsonData .get ("token" ), recaptchaAction );
342337
343338 // Check if the token is valid, score is above threshold score and the action equals expected.
344339 // Take action based on the result (BAD / NOT_BAD).
0 commit comments