Hello… I’m creating a custom service and I’m not able to use the badRequest within the service, is there any way to import or use it in some context? Thanks.
Here is an example I use inside the controller:
if (!data?.email) {
return context.badRequest('email is missing!', {
data: {
email: 'your email'
}
});
}
I’m abstracting the logic for the service, but I don’t have access to my context.