+ Start a Discussion

A catch statement that catches an exception only to rethrow it should be avoided

I am getting this error in sonarqube report, please suggest me how to avoid. below is the piece of code giving error.
Catch(Exception ex)
throw ex;
ANUTEJANUTEJ (Salesforce Developers) 
Hi Chubby,

Can you elaborate the scenario you are implementing and the issue you are facing to check further.

Looking forward to your response.