Pattern: Catching NullPointerException
Issue: -
Checks for catching a NullPointerException
. Catching NullPointerException
is never appropriate. It should be avoided in the first place with proper null checking, and it can mask underlying errors.