SONARPLUGINS-3206 Rule: Methods should not contain too many return statements
Fix some issues reported by Dory