Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Disables Style/IfUnlessModifier rule #841

Merged

Commits on Mar 8, 2023

  1. Disables Style/IfUnlessModifier rule

    Having this rule enabled forces the modifier if statement to be used
    
    So this
    
    ```
    if Apipie.configuration.swagger_api_host.present?
      @Swagger[:host] = Apipie.configuration.swagger_api_host
    end
    ```
    
    should be changed to 
    
    `@swagger[:host] = Apipie.configuration.swagger_api_host if Apipie.configuration.swagger_api_host.present?`
    
    resulting in longer, harder to read lines.
    
    Since the use the regular if statement all over the gem's codebase we can
    disable this rule.
    PanosCodes committed Mar 8, 2023
    Configuration menu
    Copy the full SHA
    e23d577 View commit details
    Browse the repository at this point in the history