The problem was when someone entered wrong order info, the app showed un authentication error instead of the real problem, like when a buyer, seller, or ad was missing. I fixed it by always using the same kind of error notice, EntityNotFoundException, I made necessary adjustments in both the OrderController and OrderService , Users now receive accurate error messages that correctly reflect the nature of the issue.
The problem was when someone entered wrong order info, the app showed un authentication error instead of the real problem, like when a buyer, seller, or ad was missing. I fixed it by always using the same kind of error notice, EntityNotFoundException, I made necessary adjustments in both the OrderController and OrderService , Users now receive accurate error messages that correctly reflect the nature of the issue.