danini-the-panini/mittsu-opengl

View on GitHub
lib/mittsu/opengl_implementation/core/geometry.rb

Summary

Maintainability
D
2 days
Test Coverage
F
55%

Class has too many lines. [258/250]
Open

  class Geometry
    include OpenGL::GeometryLike

    attr_accessor :groups, :initted

This cop checks if the length a class exceeds some maximum value. Comment lines can optionally be ignored. The maximum allowed length is configurable.

Method has too many lines. [72/30]
Open

    def set_line_buffers(hint)
      if @vertices_need_update
        @vertices.each_with_index do |vertex, v|
          offset = v * 3

This cop checks if the length of a method exceeds some maximum value. Comment lines can optionally be ignored. The maximum allowed length is configurable.

Method has too many lines. [65/30]
Open

    def set_particle_buffers(hint)
      if @vertices_need_update
        @vertices.each_with_index do |vertex, v|
          offset = v * 3

This cop checks if the length of a method exceeds some maximum value. Comment lines can optionally be ignored. The maximum allowed length is configurable.

Method set_particle_buffers has a Cognitive Complexity of 21 (exceeds 5 allowed). Consider refactoring.
Open

    def set_particle_buffers(hint)
      if @vertices_need_update
        @vertices.each_with_index do |vertex, v|
          offset = v * 3

Severity: Minor
Found in lib/mittsu/opengl_implementation/core/geometry.rb - About 2 hrs to fix

Cognitive Complexity

Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

A method's cognitive complexity is based on a few simple rules:

  • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
  • Code is considered more complex for each "break in the linear flow of the code"
  • Code is considered more complex when "flow breaking structures are nested"

Further reading

Method set_line_buffers has 72 lines of code (exceeds 25 allowed). Consider refactoring.
Open

    def set_line_buffers(hint)
      if @vertices_need_update
        @vertices.each_with_index do |vertex, v|
          offset = v * 3

Severity: Major
Found in lib/mittsu/opengl_implementation/core/geometry.rb - About 2 hrs to fix

    Method set_particle_buffers has 65 lines of code (exceeds 25 allowed). Consider refactoring.
    Open

        def set_particle_buffers(hint)
          if @vertices_need_update
            @vertices.each_with_index do |vertex, v|
              offset = v * 3
    
    
    Severity: Major
    Found in lib/mittsu/opengl_implementation/core/geometry.rb - About 2 hrs to fix

      Cyclomatic complexity for set_particle_buffers is too high. [12/6]
      Open

          def set_particle_buffers(hint)
            if @vertices_need_update
              @vertices.each_with_index do |vertex, v|
                offset = v * 3
      
      

      This cop checks that the cyclomatic complexity of methods is not higher than the configured maximum. The cyclomatic complexity is the number of linearly independent paths through a method. The algorithm counts decision points and adds one.

      An if statement (or unless or ?:) increases the complexity by one. An else branch does not, since it doesn't add a decision point. The && operator (or keyword and) can be converted to a nested if statement, and ||/or is shorthand for a sequence of ifs, so they also add one. Loops can be said to have an exit condition, so they add one.

      File geometry.rb has 263 lines of code (exceeds 250 allowed). Consider refactoring.
      Open

      require 'mittsu/opengl/geometry_like'
      
      module Mittsu
        class Geometry
          include OpenGL::GeometryLike
      Severity: Minor
      Found in lib/mittsu/opengl_implementation/core/geometry.rb - About 2 hrs to fix

        Cyclomatic complexity for set_line_buffers is too high. [10/6]
        Open

            def set_line_buffers(hint)
              if @vertices_need_update
                @vertices.each_with_index do |vertex, v|
                  offset = v * 3
        
        

        This cop checks that the cyclomatic complexity of methods is not higher than the configured maximum. The cyclomatic complexity is the number of linearly independent paths through a method. The algorithm counts decision points and adds one.

        An if statement (or unless or ?:) increases the complexity by one. An else branch does not, since it doesn't add a decision point. The && operator (or keyword and) can be converted to a nested if statement, and ||/or is shorthand for a sequence of ifs, so they also add one. Loops can be said to have an exit condition, so they add one.

        Cyclomatic complexity for init_custom_attributes is too high. [8/6]
        Open

            def init_custom_attributes(object)
              material = object.material
        
              nvertices = @vertices.length
        
        

        This cop checks that the cyclomatic complexity of methods is not higher than the configured maximum. The cyclomatic complexity is the number of linearly independent paths through a method. The algorithm counts decision points and adds one.

        An if statement (or unless or ?:) increases the complexity by one. An else branch does not, since it doesn't add a decision point. The && operator (or keyword and) can be converted to a nested if statement, and ||/or is shorthand for a sequence of ifs, so they also add one. Loops can be said to have an exit condition, so they add one.

        Method set_line_buffers has a Cognitive Complexity of 12 (exceeds 5 allowed). Consider refactoring.
        Open

            def set_line_buffers(hint)
              if @vertices_need_update
                @vertices.each_with_index do |vertex, v|
                  offset = v * 3
        
        
        Severity: Minor
        Found in lib/mittsu/opengl_implementation/core/geometry.rb - About 1 hr to fix

        Cognitive Complexity

        Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

        A method's cognitive complexity is based on a few simple rules:

        • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
        • Code is considered more complex for each "break in the linear flow of the code"
        • Code is considered more complex when "flow breaking structures are nested"

        Further reading

        Method make_groups has a Cognitive Complexity of 12 (exceeds 5 allowed). Consider refactoring.
        Open

            def make_groups(uses_face_material = false)
              max_vertices_in_group = 65535 # TODO: OES_element_index_uint ???
        
              hash_map = {}
        
        
        Severity: Minor
        Found in lib/mittsu/opengl_implementation/core/geometry.rb - About 1 hr to fix

        Cognitive Complexity

        Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

        A method's cognitive complexity is based on a few simple rules:

        • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
        • Code is considered more complex for each "break in the linear flow of the code"
        • Code is considered more complex when "flow breaking structures are nested"

        Further reading

        Method make_groups has 30 lines of code (exceeds 25 allowed). Consider refactoring.
        Open

            def make_groups(uses_face_material = false)
              max_vertices_in_group = 65535 # TODO: OES_element_index_uint ???
        
              hash_map = {}
        
        
        Severity: Minor
        Found in lib/mittsu/opengl_implementation/core/geometry.rb - About 1 hr to fix

          Method init_custom_attributes has a Cognitive Complexity of 10 (exceeds 5 allowed). Consider refactoring.
          Open

              def init_custom_attributes(object)
                material = object.material
          
                nvertices = @vertices.length
          
          
          Severity: Minor
          Found in lib/mittsu/opengl_implementation/core/geometry.rb - About 1 hr to fix

          Cognitive Complexity

          Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

          A method's cognitive complexity is based on a few simple rules:

          • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
          • Code is considered more complex for each "break in the linear flow of the code"
          • Code is considered more complex when "flow breaking structures are nested"

          Further reading

          Method init_geometry_groups has 27 lines of code (exceeds 25 allowed). Consider refactoring.
          Open

              def init_geometry_groups(object)
                material = object.material
                add_buffers = false
          
                if @groups.nil? || @groups_need_update
          Severity: Minor
          Found in lib/mittsu/opengl_implementation/core/geometry.rb - About 1 hr to fix

            Method init_geometry_groups has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring.
            Open

                def init_geometry_groups(object)
                  material = object.material
                  add_buffers = false
            
                  if @groups.nil? || @groups_need_update
            Severity: Minor
            Found in lib/mittsu/opengl_implementation/core/geometry.rb - About 45 mins to fix

            Cognitive Complexity

            Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

            A method's cognitive complexity is based on a few simple rules:

            • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
            • Code is considered more complex for each "break in the linear flow of the code"
            • Code is considered more complex when "flow breaking structures are nested"

            Further reading

            TODO found
            Open

                  max_vertices_in_group = 65535 # TODO: OES_element_index_uint ???

            Similar blocks of code found in 4 locations. Consider refactoring.
            Open

                  if @colors_need_update
                    @colors.each_with_index do |color, c|
                      offset = c * 3;
            
                      @color_array[offset]     = color.r
            Severity: Major
            Found in lib/mittsu/opengl_implementation/core/geometry.rb and 3 other locations - About 50 mins to fix
            lib/mittsu/opengl_implementation/core/geometry.rb on lines 93..103
            lib/mittsu/opengl_implementation/core/geometry.rb on lines 106..116
            lib/mittsu/opengl_implementation/core/geometry.rb on lines 184..195

            Duplicated Code

            Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

            Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

            When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

            Tuning

            This issue has a mass of 42.

            We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

            The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

            If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

            See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

            Refactorings

            Further Reading

            Similar blocks of code found in 4 locations. Consider refactoring.
            Open

                  if @vertices_need_update
                    @vertices.each_with_index do |vertex, v|
                      offset = v * 3
            
                      @vertex_array[offset]     = vertex.x
            Severity: Major
            Found in lib/mittsu/opengl_implementation/core/geometry.rb and 3 other locations - About 50 mins to fix
            lib/mittsu/opengl_implementation/core/geometry.rb on lines 106..116
            lib/mittsu/opengl_implementation/core/geometry.rb on lines 184..195
            lib/mittsu/opengl_implementation/core/geometry.rb on lines 198..208

            Duplicated Code

            Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

            Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

            When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

            Tuning

            This issue has a mass of 42.

            We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

            The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

            If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

            See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

            Refactorings

            Further Reading

            Similar blocks of code found in 4 locations. Consider refactoring.
            Open

                  if @colors_need_update
                    @colors.each_with_index do |color, c|
                      offset = c * 3
            
                      @color_array[offset]     = color.r
            Severity: Major
            Found in lib/mittsu/opengl_implementation/core/geometry.rb and 3 other locations - About 50 mins to fix
            lib/mittsu/opengl_implementation/core/geometry.rb on lines 93..103
            lib/mittsu/opengl_implementation/core/geometry.rb on lines 184..195
            lib/mittsu/opengl_implementation/core/geometry.rb on lines 198..208

            Duplicated Code

            Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

            Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

            When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

            Tuning

            This issue has a mass of 42.

            We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

            The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

            If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

            See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

            Refactorings

            Further Reading

            Similar blocks of code found in 4 locations. Consider refactoring.
            Open

                  if @vertices_need_update
                    @vertices.each_with_index do |vertex, v|
                      offset = v * 3
            
                      @vertex_array[offset]     = vertex.x
            Severity: Major
            Found in lib/mittsu/opengl_implementation/core/geometry.rb and 3 other locations - About 50 mins to fix
            lib/mittsu/opengl_implementation/core/geometry.rb on lines 93..103
            lib/mittsu/opengl_implementation/core/geometry.rb on lines 106..116
            lib/mittsu/opengl_implementation/core/geometry.rb on lines 198..208

            Duplicated Code

            Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

            Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

            When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

            Tuning

            This issue has a mass of 42.

            We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

            The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

            If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

            See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

            Refactorings

            Further Reading

            Similar blocks of code found in 2 locations. Consider refactoring.
            Open

                            custom_attribute.array[offset]     = value.x
                            custom_attribute.array[offset + 1] = value.y
                            custom_attribute.array[offset + 2] = value.z
                            custom_attribute.array[offset + 3] = value.w
            
            
            Severity: Minor
            Found in lib/mittsu/opengl_implementation/core/geometry.rb and 1 other location - About 35 mins to fix
            lib/mittsu/opengl_implementation/core/geometry.rb on lines 166..172

            Duplicated Code

            Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

            Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

            When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

            Tuning

            This issue has a mass of 35.

            We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

            The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

            If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

            See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

            Refactorings

            Further Reading

            Similar blocks of code found in 2 locations. Consider refactoring.
            Open

                          custom_attribute.array[offset    ] = value.x
                          custom_attribute.array[offset + 1] = value.y
                          custom_attribute.array[offset + 2] = value.z
                          custom_attribute.array[offset + 3] = value.w
            
            
            Severity: Minor
            Found in lib/mittsu/opengl_implementation/core/geometry.rb and 1 other location - About 35 mins to fix
            lib/mittsu/opengl_implementation/core/geometry.rb on lines 247..253

            Duplicated Code

            Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

            Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

            When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

            Tuning

            This issue has a mass of 35.

            We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

            The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

            If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

            See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

            Refactorings

            Further Reading

            Similar blocks of code found in 2 locations. Consider refactoring.
            Open

                            custom_attribute.value.each do |value|
                              custom_attribute.array[offset]     = value.r
                              custom_attribute.array[offset + 1] = value.g
                              custom_attribute.array[offset + 2] = value.b
            
            
            Severity: Minor
            Found in lib/mittsu/opengl_implementation/core/geometry.rb and 1 other location - About 30 mins to fix
            lib/mittsu/opengl_implementation/core/geometry.rb on lines 237..243

            Duplicated Code

            Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

            Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

            When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

            Tuning

            This issue has a mass of 32.

            We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

            The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

            If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

            See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

            Refactorings

            Further Reading

            Similar blocks of code found in 2 locations. Consider refactoring.
            Open

                            custom_attribute.value.each do |value|
                              custom_attribute.array[offset]     = value.x
                              custom_attribute.array[offset + 1] = value.y
                              custom_attribute.array[offset + 2] = value.z
            
            
            Severity: Minor
            Found in lib/mittsu/opengl_implementation/core/geometry.rb and 1 other location - About 30 mins to fix
            lib/mittsu/opengl_implementation/core/geometry.rb on lines 229..235

            Duplicated Code

            Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

            Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

            When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

            Tuning

            This issue has a mass of 32.

            We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

            The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

            If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

            See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

            Refactorings

            Further Reading

            Similar blocks of code found in 2 locations. Consider refactoring.
            Open

                          values.each do |value|
                            custom_attribute.array[offset    ] = value.x
                            custom_attribute.array[offset + 1] = value.y
                            custom_attribute.array[offset + 2] = value.z
            
            
            Severity: Minor
            Found in lib/mittsu/opengl_implementation/core/geometry.rb and 1 other location - About 25 mins to fix
            lib/mittsu/opengl_implementation/core/geometry.rb on lines 148..154

            Duplicated Code

            Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

            Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

            When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

            Tuning

            This issue has a mass of 31.

            We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

            The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

            If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

            See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

            Refactorings

            Further Reading

            Similar blocks of code found in 2 locations. Consider refactoring.
            Open

                          values.each do |value|
                            custom_attribute.array[offset    ] = value.r
                            custom_attribute.array[offset + 1] = value.g
                            custom_attribute.array[offset + 2] = value.b
            
            
            Severity: Minor
            Found in lib/mittsu/opengl_implementation/core/geometry.rb and 1 other location - About 25 mins to fix
            lib/mittsu/opengl_implementation/core/geometry.rb on lines 156..162

            Duplicated Code

            Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

            Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

            When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

            Tuning

            This issue has a mass of 31.

            We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

            The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

            If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

            See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

            Refactorings

            Further Reading

            end at 329, 12 is not aligned with case at 323, 19.
            Open

                        end

            This cop checks whether the end keywords are aligned properly.

            Three modes are supported through the EnforcedStyleAlignWith configuration parameter:

            If it's set to keyword (which is the default), the end shall be aligned with the start of the keyword (if, class, etc.).

            If it's set to variable the end shall be aligned with the left-hand-side of the variable assignment, if there is one.

            If it's set to start_of_line, the end shall be aligned with the start of the line where the matching keyword appears.

            Example: EnforcedStyleAlignWith: keyword (default)

            # bad
            
            variable = if true
                end
            
            # good
            
            variable = if true
                       end

            Example: EnforcedStyleAlignWith: variable

            # bad
            
            variable = if true
                end
            
            # good
            
            variable = if true
            end

            Example: EnforcedStyleAlignWith: startofline

            # bad
            
            variable = if true
                end
            
            # good
            
            puts(if true
            end)

            There are no issues that match your filters.

            Category
            Status