Skip to content

Change tip for CollapsibleIfStatements #81

@nbirillo

Description

@nbirillo
        if (index > 0) {
            if (numbers[index - 1] == 3) {
                return true;
            }
        }

Current feedback:

    {
      "code": "CollapsibleIfStatements",
      "text": "These nested if statements could be combined",
      "line": "if (numbers[index + 1] == 3) {",
      "line_number": 23,
      "column_number": 1,
      "category": "BEST_PRACTICES",
      "influence_on_penalty": 0
    }

Change the tip into These nested if statements could be combined by && operator

Metadata

Metadata

Labels

enhancementNew feature or requesthelp wantedExtra attention is needed

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions