Address all the changes reported/recommended by `gosimple` tool.
Added checks to look for duplicated notification configs. Fixes #2472