New Year Sale 2026! 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 1 Question 78 Discussion

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

A controller route in the SFRA base looks as follows:

In order to extend this route using prepared ( ), what should the developer consider?

Show Suggested Answer Hide Answer
Suggested Answer: B

Contribute your Thoughts:

0/2000 characters
Ashleigh
2 months ago
Totally agree with A, can't overlook middleware!
upvoted 0 times
...
Tish
3 months ago
I think B makes more sense, sticking to the base route's middleware.
upvoted 0 times
...
Miesha
3 months ago
Wait, are we really supposed to remove next()? That sounds off.
upvoted 0 times
...
Denna
3 months ago
C seems risky, removing next() could break things.
upvoted 0 times
...
Rodrigo
3 months ago
A is definitely the way to go! Middleware is key.
upvoted 0 times
...
Adelle
3 months ago
I feel like removing next() could lead to issues, but I can't quite remember why we would want to keep it in some cases.
upvoted 0 times
...
Raina
4 months ago
This question feels familiar; I think we practiced something similar where we had to decide on middleware for extending routes. I hope I remember the right approach!
upvoted 0 times
...
Bok
4 months ago
I think we might need to specify any middleware functions needed for the new functionality, but I can't recall if we should limit it to just the base route's middleware.
upvoted 0 times
...
Dorinda
4 months ago
I remember we talked about middleware functions in class, but I'm not sure if we should only use those from the base route or if we can add new ones too.
upvoted 0 times
...
Trinidad
4 months ago
Removing the next() call seems risky to me. I don't want to break the existing functionality, so I'll stick with using the middleware functions from the base route.
upvoted 0 times
...
Annamae
4 months ago
I'm a bit confused about the "prepared()" part of the question. Does that mean I need to use some kind of prepared statement or query? I'll have to research that a bit more.
upvoted 0 times
...
Jacklyn
5 months ago
Okay, I think the key here is to only use the middleware functions called by the base route. That way, I can extend the functionality without disrupting the existing flow.
upvoted 0 times
...
Ellsworth
5 months ago
Hmm, this looks like a tricky one. I'll need to carefully review the base route and consider what additional middleware functions might be needed for the new functionality.
upvoted 0 times
...
Annelle
5 months ago
Hmm, I'm a bit unsure about this one. The options seem to cover different aspects of the knowledgebase, but I'm not sure which one is the primary purpose. I'll have to think this through step-by-step.
upvoted 0 times
...
King
1 year ago
This question is a great way to test our understanding of SFRA routing. I'm glad they're not asking us to write code from scratch - that would be a real brain-buster!
upvoted 0 times
Lavelle
1 year ago
I agree, it's a good way to test our knowledge without overwhelming us with coding from scratch.
upvoted 0 times
...
Dorinda
1 year ago
B) Specify any middleware functions needed for the new functionality using only those called by the base route.
upvoted 0 times
...
Alana
1 year ago
A) Specify any middleware functions needed for the new functionality.
upvoted 0 times
...
...
Layla
1 year ago
Haha, I love how the question is phrased. It's almost like they're trying to trip us up with those silly answer choices. But B is clearly the way to go here.
upvoted 0 times
...
Sharita
1 year ago
I was a bit confused by the question at first, but after looking at the code, I agree that B is the best option. Removing next() would be a bad idea.
upvoted 0 times
Virgie
1 year ago
Yes, specifying only the necessary middleware functions is the way to go. B is the best choice.
upvoted 0 times
...
Dorothy
1 year ago
I agree, removing next() would cause issues. B is the safest option.
upvoted 0 times
...
Karma
1 year ago
I think B is the correct answer. It makes sense to only use middleware functions called by the base route.
upvoted 0 times
...
...
Yun
1 year ago
Definitely, B is the correct answer. We should only specify the middleware functions that are called by the base route, not any other functions.
upvoted 0 times
Felix
1 year ago
By following option B, we ensure that the extended route remains streamlined and optimized.
upvoted 0 times
...
Kathrine
1 year ago
It's important to maintain the integrity of the base route by not adding unnecessary middleware functions.
upvoted 0 times
...
Cecily
1 year ago
I agree, B is the way to go. We need to stick to the middleware functions called by the base route.
upvoted 0 times
...
Hollis
1 year ago
Exactly, specifying only the necessary middleware functions keeps the route clean and efficient.
upvoted 0 times
...
...
Holley
1 year ago
I think removing next(); on the new route is also important to ensure only the route's middleware functions execute.
upvoted 0 times
...
Micheal
1 year ago
I agree with Bambi, adding middleware functions is important for extending the route.
upvoted 0 times
...
Bambi
1 year ago
I think the developer should consider specifying any middleware functions needed for the new functionality.
upvoted 0 times
...
Keneth
1 year ago
The key here is to consider the middleware functions used by the base route. Extending the route using prepared() will require adding any additional middleware needed for the new functionality.
upvoted 0 times
Thomasena
1 year ago
C) Remove next(); on the new route so only the route's middleware functions execute.
upvoted 0 times
...
Julieta
1 year ago
B) Specify any middleware functions needed for the new functionality using only those called by the base route.
upvoted 0 times
...
Deangelo
1 year ago
A) Specify any middleware functions needed for the new functionality.
upvoted 0 times
...
...

Save Cancel