Deal of The Day! Hurry Up, Grab the Special Discount - Save 25% - Ends In 00:00:00 Coupon code: SAVE25
Welcome to Pass4Success

- Free Preparation Discussions

Salesforce Certified B2C Commerce Cloud Developer (Comm-Dev-101) Exam - Topic 2 Question 102 Discussion

Actual exam question for Salesforce's Salesforce Certified B2C Commerce Cloud Developer (Comm-Dev-101) exam
Question #: 102
Topic #: 2
[All Salesforce Certified B2C Commerce Cloud Developer (Comm-Dev-101) Questions]

Server.get('Show', consentTracking.consent, cache.applyDefaultCache, function (req,res,next){

Var Site = require('dw/system/Syte'');

Var pageMetaHelpter = require('*/cartridge/scripts/helpers/pageMetaHelper');

pageMetaHelpter.setPageMetaTags(req.pageMetaData, Site.current);

res.render('/home/homePage');

Missing code here

}, pageMetadata.computedPageMetadata);

The controller endpoint code snippet above does not work.

Which line of code should the developer use to replace line 6 and correct the problem?

Show Suggested Answer Hide Answer
Suggested Answer: A

Contribute your Thoughts:

0/2000 characters
Marti
9 days ago
I’m confused about the options. I don’t recall seeing req.next() in practice, so I’m leaning towards A) next() as well, but I’m not completely confident.
upvoted 0 times
...
Glendora
14 days ago
I feel like I've seen something like this before, and I thought it was always about calling next() to continue the flow. So A) next(); seems likely.
upvoted 0 times
...
Nelida
19 days ago
I'm not entirely sure, but I remember something about using return statements in similar questions. Maybe B) return res; could be correct?
upvoted 0 times
...
Lilli
24 days ago
I think the answer might be A) next(); since it seems like we need to pass control to the next middleware.
upvoted 0 times
...

Save Cancel