hackedteam/core-ios

View on GitHub
ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift

Summary

Maintainability
D
2 days
Test Coverage

Function drawGlobe has 55 lines of code (exceeds 25 allowed). Consider refactoring.
Open

func drawGlobe(bounds: CGRect, color: UIColor) {
    let factors = getFactors(CGSizeMake(41, 40), bounds)
    let xScalingFactor = factors.xScalingFactor
    let yScalingFactor = factors.yScalingFactor
    let lineWidthScalingFactor = factors.lineWidthScalingFactor
Severity: Major
Found in ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift - About 2 hrs to fix

    Function drawBackspace has 40 lines of code (exceeds 25 allowed). Consider refactoring.
    Open

    func drawBackspace(bounds: CGRect, color: UIColor) {
        let factors = getFactors(CGSizeMake(44, 32), bounds)
        let xScalingFactor = factors.xScalingFactor
        let yScalingFactor = factors.yScalingFactor
        let lineWidthScalingFactor = factors.lineWidthScalingFactor
    Severity: Minor
    Found in ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift - About 1 hr to fix

      Function drawShift has 28 lines of code (exceeds 25 allowed). Consider refactoring.
      Open

      func drawShift(bounds: CGRect, color: UIColor, withRect: Bool) {
          let factors = getFactors(CGSizeMake(38, (withRect ? 34 + 4 : 32)), bounds)
          let xScalingFactor = factors.xScalingFactor
          let yScalingFactor = factors.yScalingFactor
          let lineWidthScalingFactor = factors.lineWidthScalingFactor
      Severity: Minor
      Found in ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift - About 1 hr to fix

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

            bezierPath.addCurveToPoint(CGPointMake(14 * xScalingFactor, 32 * yScalingFactor), controlPoint1: CGPointMake(10 * xScalingFactor, 28 * yScalingFactor), controlPoint2: CGPointMake(10 * xScalingFactor, 32 * yScalingFactor))
        Severity: Major
        Found in ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift and 11 other locations - About 55 mins to fix
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 168..168
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 169..169
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 170..170
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 171..171
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 230..230
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 231..231
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 232..232
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 292..292
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 303..303
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 314..314
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 325..325

        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 66.

        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 12 locations. Consider refactoring.
        Open

            bezierPath.addCurveToPoint(CGPointMake(28 * xScalingFactor, 28 * yScalingFactor), controlPoint1: CGPointMake(24 * xScalingFactor, 32 * yScalingFactor), controlPoint2: CGPointMake(28 * xScalingFactor, 32 * yScalingFactor))
        Severity: Major
        Found in ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift and 11 other locations - About 55 mins to fix
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 168..168
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 169..169
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 170..170
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 171..171
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 229..229
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 230..230
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 232..232
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 292..292
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 303..303
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 314..314
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 325..325

        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 66.

        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 12 locations. Consider refactoring.
        Open

            bezier3Path.addCurveToPoint(CGPointMake(21.63 * xScalingFactor, 39.6 * yScalingFactor), controlPoint1: CGPointMake(21.63 * xScalingFactor, 0.42 * yScalingFactor), controlPoint2: CGPointMake(41 * xScalingFactor, 19 * yScalingFactor))
        Severity: Major
        Found in ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift and 11 other locations - About 55 mins to fix
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 168..168
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 169..169
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 170..170
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 171..171
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 229..229
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 230..230
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 231..231
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 232..232
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 303..303
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 314..314
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 325..325

        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 66.

        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 12 locations. Consider refactoring.
        Open

            bezierPath.addCurveToPoint(CGPointMake(44 * xScalingFactor, 26 * yScalingFactor), controlPoint1: CGPointMake(38 * xScalingFactor, 32 * yScalingFactor), controlPoint2: CGPointMake(44 * xScalingFactor, 32 * yScalingFactor))
        Severity: Major
        Found in ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift and 11 other locations - About 55 mins to fix
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 169..169
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 170..170
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 171..171
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 229..229
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 230..230
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 231..231
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 232..232
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 292..292
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 303..303
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 314..314
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 325..325

        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 66.

        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 12 locations. Consider refactoring.
        Open

            bezierPath.addCurveToPoint(CGPointMake(28 * xScalingFactor, 18 * yScalingFactor), controlPoint1: CGPointMake(28 * xScalingFactor, 26 * yScalingFactor), controlPoint2: CGPointMake(28 * xScalingFactor, 18 * yScalingFactor))
        Severity: Major
        Found in ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift and 11 other locations - About 55 mins to fix
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 168..168
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 169..169
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 170..170
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 171..171
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 229..229
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 230..230
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 231..231
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 292..292
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 303..303
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 314..314
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 325..325

        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 66.

        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 12 locations. Consider refactoring.
        Open

            bezier6Path.addCurveToPoint(CGPointMake(34 * xScalingFactor, 33 * yScalingFactor), controlPoint1: CGPointMake(6 * xScalingFactor, 33 * yScalingFactor), controlPoint2: CGPointMake(19 * xScalingFactor, 22 * yScalingFactor))
        Severity: Major
        Found in ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift and 11 other locations - About 55 mins to fix
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 168..168
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 169..169
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 170..170
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 171..171
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 229..229
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 230..230
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 231..231
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 232..232
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 292..292
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 303..303
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 314..314

        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 66.

        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 12 locations. Consider refactoring.
        Open

            bezierPath.addCurveToPoint(CGPointMake(36 * xScalingFactor, 0 * yScalingFactor), controlPoint1: CGPointMake(44 * xScalingFactor, 6 * yScalingFactor), controlPoint2: CGPointMake(44 * xScalingFactor, 0 * yScalingFactor))
        Severity: Major
        Found in ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift and 11 other locations - About 55 mins to fix
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 168..168
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 169..169
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 171..171
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 229..229
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 230..230
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 231..231
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 232..232
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 292..292
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 303..303
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 314..314
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 325..325

        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 66.

        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 12 locations. Consider refactoring.
        Open

            bezier4Path.addCurveToPoint(CGPointMake(18.72 * xScalingFactor, 39.6 * yScalingFactor), controlPoint1: CGPointMake(17.76 * xScalingFactor, 0.74 * yScalingFactor), controlPoint2: CGPointMake(-2.5 * xScalingFactor, 19.04 * yScalingFactor))
        Severity: Major
        Found in ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift and 11 other locations - About 55 mins to fix
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 168..168
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 169..169
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 170..170
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 171..171
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 229..229
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 230..230
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 231..231
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 232..232
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 292..292
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 314..314
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 325..325

        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 66.

        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 12 locations. Consider refactoring.
        Open

            bezierPath.addCurveToPoint(CGPointMake(16 * xScalingFactor, 0 * yScalingFactor), controlPoint1: CGPointMake(32 * xScalingFactor, 0 * yScalingFactor), controlPoint2: CGPointMake(16 * xScalingFactor, 0 * yScalingFactor))
        Severity: Major
        Found in ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift and 11 other locations - About 55 mins to fix
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 168..168
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 169..169
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 170..170
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 229..229
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 230..230
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 231..231
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 232..232
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 292..292
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 303..303
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 314..314
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 325..325

        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 66.

        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 12 locations. Consider refactoring.
        Open

            bezierPath.addCurveToPoint(CGPointMake(24 * xScalingFactor, 32 * yScalingFactor), controlPoint1: CGPointMake(16 * xScalingFactor, 32 * yScalingFactor), controlPoint2: CGPointMake(24 * xScalingFactor, 32 * yScalingFactor))
        Severity: Major
        Found in ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift and 11 other locations - About 55 mins to fix
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 168..168
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 169..169
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 170..170
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 171..171
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 229..229
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 231..231
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 232..232
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 292..292
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 303..303
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 314..314
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 325..325

        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 66.

        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 12 locations. Consider refactoring.
        Open

            bezier5Path.addCurveToPoint(CGPointMake(34 * xScalingFactor, 7 * yScalingFactor), controlPoint1: CGPointMake(6 * xScalingFactor, 7 * yScalingFactor), controlPoint2: CGPointMake(19 * xScalingFactor, 21 * yScalingFactor))
        Severity: Major
        Found in ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift and 11 other locations - About 55 mins to fix
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 168..168
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 169..169
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 170..170
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 171..171
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 229..229
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 230..230
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 231..231
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 232..232
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 292..292
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 303..303
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 325..325

        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 66.

        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 12 locations. Consider refactoring.
        Open

            bezierPath.addCurveToPoint(CGPointMake(44 * xScalingFactor, 6 * yScalingFactor), controlPoint1: CGPointMake(44 * xScalingFactor, 22 * yScalingFactor), controlPoint2: CGPointMake(44 * xScalingFactor, 6 * yScalingFactor))
        Severity: Major
        Found in ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift and 11 other locations - About 55 mins to fix
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 168..168
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 170..170
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 171..171
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 229..229
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 230..230
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 231..231
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 232..232
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 292..292
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 303..303
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 314..314
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 325..325

        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 66.

        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

                self.overflowCanvas.frame = CGRectMake(
                    CGFloat((self.bounds.width - overflowCanvasSize.width) / 2.0),
                    CGFloat((self.bounds.height - overflowCanvasSize.height) / 2.0),
                    overflowCanvasSize.width,
                    overflowCanvasSize.height)
        Severity: Minor
        Found in ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift and 1 other location - About 50 mins to fix
        ios-newsstand-app/newsstand-app/Keyboard/KeyboardKey.swift on lines 373..377

        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 61.

        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

                let rectanglePath = UIBezierPath(rect: CGRectMake(10 * xScalingFactor, 34 * yScalingFactor, 18 * xScalingFactor, 4 * yScalingFactor))
        Severity: Minor
        Found in ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift and 1 other location - About 35 mins to fix
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 261..261

        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 43.

        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

            var ovalPath = UIBezierPath(ovalInRect: CGRectMake(0 * xScalingFactor, 0 * yScalingFactor, 40 * xScalingFactor, 40 * yScalingFactor))
        Severity: Minor
        Found in ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift and 1 other location - About 35 mins to fix
        ios-newsstand-app/newsstand-app/Keyboard/Shapes.swift on lines 240..240

        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 43.

        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

        There are no issues that match your filters.

        Category
        Status