SeunAdelekan/Kanary

View on GitHub
src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt

Summary

Maintainability
D
2 days
Test Coverage

Class AppRouter has 25 methods (exceeds 20 allowed). Consider refactoring.
Open

/**
 * @author Iyanu Adelekan on 16/08/2018.
 *
 * Core application router class. Utilize instances of this class
 * to compose server routes. Upon composition of a route it must be
Severity: Minor
Found in src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt - About 2 hrs to fix

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

        /**
         * Handles LINK requests.
         *
         * @param [path] - request path.
         * @param [routerAction] - router action.
    Severity: Major
    Found in src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt and 8 other locations - About 1 hr to fix
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 95..106
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 120..131
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 145..156
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 170..181
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 195..206
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 220..231
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 245..256
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 295..306

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

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

        /**
         * Handles POST requests.
         *
         * @param [path] - request path.
         * @param [routerAction] - router action.
    Severity: Major
    Found in src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt and 8 other locations - About 1 hr to fix
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 95..106
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 145..156
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 170..181
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 195..206
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 220..231
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 245..256
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 270..281
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 295..306

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

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

        /**
         * Handles OPTIONS requests.
         *
         * @param [path] - request path.
         * @param [routerAction] - router action.
    Severity: Major
    Found in src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt and 8 other locations - About 1 hr to fix
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 95..106
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 120..131
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 145..156
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 170..181
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 220..231
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 245..256
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 270..281
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 295..306

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

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

        /**
         * Handles PATCH requests.
         *
         * @param [path] - request path.
         * @param [routerAction] - router action.
    Severity: Major
    Found in src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt and 8 other locations - About 1 hr to fix
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 95..106
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 120..131
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 145..156
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 170..181
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 195..206
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 220..231
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 270..281
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 295..306

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

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

        /**
         * Handles GET requests.
         *
         * @param [path] - request path.
         * @param [routerAction] - router action.
    Severity: Major
    Found in src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt and 8 other locations - About 1 hr to fix
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 120..131
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 145..156
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 170..181
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 195..206
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 220..231
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 245..256
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 270..281
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 295..306

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

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

        /**
         * Handles DELETE requests.
         *
         * @param [path] - request path.
         * @param [routerAction] - router action.
    Severity: Major
    Found in src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt and 8 other locations - About 1 hr to fix
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 95..106
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 120..131
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 145..156
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 195..206
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 220..231
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 245..256
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 270..281
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 295..306

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

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

        /**
         * Handles HEAD requests.
         *
         * @param [path] - request path.
         * @param [routerAction] - router action.
    Severity: Major
    Found in src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt and 8 other locations - About 1 hr to fix
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 95..106
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 120..131
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 145..156
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 170..181
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 195..206
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 245..256
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 270..281
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 295..306

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

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

        /**
         * Handles PUT requests.
         *
         * @param [path] - request path.
         * @param [routerAction] - router action.
    Severity: Major
    Found in src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt and 8 other locations - About 1 hr to fix
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 95..106
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 120..131
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 170..181
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 195..206
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 220..231
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 245..256
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 270..281
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 295..306

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

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

        /**
         * Handles UNLINK requests.
         *
         * @param [path] - request path.
         * @param [routerAction] - router action.
    Severity: Major
    Found in src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt and 8 other locations - About 1 hr to fix
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 95..106
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 120..131
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 145..156
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 170..181
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 195..206
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 220..231
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 245..256
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 270..281

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

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

        /**
         * Handles POST requests.
         *
         * @param [path] - request path.
         * @param [routerAction] - router action.
    Severity: Major
    Found in src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt and 8 other locations - About 50 mins to fix
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 83..93
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 133..143
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 158..168
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 183..193
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 208..218
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 233..243
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 258..268
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 283..293

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

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

        /**
         * Handles HEAD requests.
         *
         * @param [path] - request path.
         * @param [routerAction] - router action.
    Severity: Major
    Found in src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt and 8 other locations - About 50 mins to fix
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 83..93
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 108..118
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 133..143
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 158..168
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 183..193
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 233..243
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 258..268
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 283..293

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

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

        /**
         * Handles LINK requests.
         *
         * @param [path] - request path.
         * @param [routerAction] - router action.
    Severity: Major
    Found in src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt and 8 other locations - About 50 mins to fix
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 83..93
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 108..118
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 133..143
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 158..168
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 183..193
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 208..218
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 233..243
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 283..293

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

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

        /**
         * Handles PUT requests.
         *
         * @param [path] - request path.
         * @param [routerAction] - router action.
    Severity: Major
    Found in src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt and 8 other locations - About 50 mins to fix
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 83..93
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 108..118
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 158..168
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 183..193
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 208..218
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 233..243
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 258..268
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 283..293

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

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

        /**
         * Handles PATCH requests.
         *
         * @param [path] - request path.
         * @param [routerAction] - router action.
    Severity: Major
    Found in src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt and 8 other locations - About 50 mins to fix
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 83..93
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 108..118
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 133..143
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 158..168
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 183..193
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 208..218
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 258..268
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 283..293

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

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

        /**
         * Handles UNLINK requests.
         *
         * @param [path] - request path.
         * @param [routerAction] - router action.
    Severity: Major
    Found in src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt and 8 other locations - About 50 mins to fix
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 83..93
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 108..118
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 133..143
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 158..168
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 183..193
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 208..218
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 233..243
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 258..268

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

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

        /**
         * Handles GET requests.
         *
         * @param [path] - request path.
         * @param [routerAction] - router action.
    Severity: Major
    Found in src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt and 8 other locations - About 50 mins to fix
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 108..118
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 133..143
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 158..168
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 183..193
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 208..218
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 233..243
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 258..268
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 283..293

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

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

        /**
         * Handles DELETE requests.
         *
         * @param [path] - request path.
         * @param [routerAction] - router action.
    Severity: Major
    Found in src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt and 8 other locations - About 50 mins to fix
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 83..93
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 108..118
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 133..143
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 183..193
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 208..218
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 233..243
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 258..268
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 283..293

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

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

        /**
         * Handles OPTIONS requests.
         *
         * @param [path] - request path.
         * @param [routerAction] - router action.
    Severity: Major
    Found in src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt and 8 other locations - About 50 mins to fix
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 83..93
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 108..118
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 133..143
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 158..168
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 208..218
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 233..243
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 258..268
    src/main/com/iyanuadelekan/kanary/app/router/AppRouter.kt on lines 283..293

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

    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