GladysProject/Gladys

View on GitHub
front/src/config/demo.js

Summary

Maintainability
F
1 mo
Test Coverage

File demo.js has 4161 lines of code (exceeds 250 allowed). Consider refactoring.
Open

import dayjs from 'dayjs';

const data = {
  'post /api/v1/login': {
    id: '215811c9-c0aa-4148-8a4b-e02892d7446f',
Severity: Major
Found in front/src/config/demo.js - About 1 wk to fix

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

      'get /api/v1/device?device_feature_selectors=main-lamp-binary,tv-lamp-binary,tv-lamp-color,tv-lamp-brightness,mqtt-living-room-switch,mqtt-living-room-dimmer,mqtt-living-room-temp,co-living-room': [
        {
          id: '20deebe6-57df-4940-afd1-11c189a407c2',
          name: 'TV',
          selector: 'main-tv',
    Severity: Major
    Found in front/src/config/demo.js and 1 other location - About 6 days to fix
    front/src/config/demo.js on lines 2644..2888

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

    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

      'get /api/v1/device?device_feature_selectors=main-tv-binary,main-tv-volume,main-tv-channel,main-presence-sensor,main-signal-sensor,air-conditioning,button-click': [
        {
          id: '20deebe6-57df-4940-afd1-11c189a407c2',
          name: 'TV',
          selector: 'main-tv',
    Severity: Major
    Found in front/src/config/demo.js and 1 other location - About 6 days to fix
    front/src/config/demo.js on lines 3009..3253

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

    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

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

        devices: [
          {
            id: 'f131fbf2-445a-4c2c-9426-83abaf534662',
            name: 'Room sensors',
            selector: 'room-sensors',
    Severity: Major
    Found in front/src/config/demo.js and 1 other location - About 2 days to fix
    front/src/config/demo.js on lines 2889..3008

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

    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

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

      'get /api/v1/device?device_feature_selectors=curtain-actions,shutter-actions,shutter-position,thermostat,water-leak,smoke-sensor,light-sensor': [
        {
          id: 'f131fbf2-445a-4c2c-9426-83abaf534662',
          name: 'Room sensors',
          selector: 'room-sensors',
    Severity: Major
    Found in front/src/config/demo.js and 1 other location - About 2 days to fix
    front/src/config/demo.js on lines 329..448

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

    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

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

        {
          id: 'e5317b24-28e1-4839-9879-0bb7a3102e98',
          name: 'Xiaomi Temperature',
          external_id: 'xiaomi:1234',
          selector: 'xiaomi:1234',
    Severity: Major
    Found in front/src/config/demo.js and 1 other location - About 1 day to fix
    front/src/config/demo.js on lines 3313..3361

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

    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

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

      'get /api/v1/device/xiaomi:1234': {
        id: 'e5317b24-28e1-4839-9879-0bb7a3102e98',
        name: 'Xiaomi Temperature',
        external_id: 'xiaomi:1234',
        selector: 'xiaomi:1234',
    Severity: Major
    Found in front/src/config/demo.js and 1 other location - About 1 day to fix
    front/src/config/demo.js on lines 2573..2621

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

    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

        {
          service_id: 'd1af258c-2016-4dc9-b0cc-d2e92dd2fcec',
          name: 'New device',
          ip: '192.168.1.10',
          can_save: true,
    Severity: Major
    Found in front/src/config/demo.js and 1 other location - About 5 hrs to fix
    front/src/config/demo.js on lines 2489..2522

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

    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

        {
          service_id: 'd1af258c-2016-4dc9-b0cc-d2e92dd2fcec',
          name: 'Random MAC device',
          ip: '192.168.1.100',
          can_save: false,
    Severity: Major
    Found in front/src/config/demo.js and 1 other location - About 5 hrs to fix
    front/src/config/demo.js on lines 2455..2488

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

    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

      'get /api/v1/service/tp-link/device': [
        {
          id: '1',
          name: 'Plug Coffee Machine',
          model: 'HS100',
    Severity: Major
    Found in front/src/config/demo.js and 1 other location - About 4 hrs to fix
    front/src/config/demo.js on lines 3801..3832

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

    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

      'get /api/v1/service/tp-link/scan': [
        {
          id: '3',
          name: 'Plug TV Dock',
          model: 'HS100',
    Severity: Major
    Found in front/src/config/demo.js and 1 other location - About 4 hrs to fix
    front/src/config/demo.js on lines 3769..3800

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

    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

        {
          id: 'fbedb47f-4d25-4381-8923-2633b23192a0',
          service_id: 'a810b8db-6d04-4697-bed3-c4b72c996279',
          room_id: 'cecc52c7-3e67-4b75-9b13-9a8867b0443d',
          name: 'Nut Smart Tracker',
    Severity: Major
    Found in front/src/config/demo.js and 1 other location - About 3 hrs to fix
    front/src/config/demo.js on lines 3490..3515

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

    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

      'get /api/v1/device/bluetooth-sensor': {
        id: 'fbedb47f-4d25-4381-8923-2633b23192a0',
        service_id: 'a810b8db-6d04-4697-bed3-c4b72c996279',
        room_id: 'cecc52c7-3e67-4b75-9b13-9a8867b0443d',
        name: 'Nut Smart Tracker',
    Severity: Major
    Found in front/src/config/demo.js and 1 other location - About 3 hrs to fix
    front/src/config/demo.js on lines 3463..3488

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

    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

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

        {
          id: 'af3e166e-64f1-444d-a5fe-90ceaa1fc176',
          name: 'Exterior',
          selector: 'exterior',
          devices: [
    Severity: Major
    Found in front/src/config/demo.js and 1 other location - About 3 hrs to fix
    front/src/config/demo.js on lines 299..324

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

    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

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

      'get /api/v1/room/exterior': {
        id: 'af3e166e-64f1-444d-a5fe-90ceaa1fc176',
        name: 'Exterior',
        selector: 'exterior',
        devices: [
    Severity: Major
    Found in front/src/config/demo.js and 1 other location - About 3 hrs to fix
    front/src/config/demo.js on lines 960..985

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

    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

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

        features: [
          {
            name: 'Battery',
            category: 'battery',
            type: 'integer',
    Severity: Major
    Found in front/src/config/demo.js and 1 other location - About 3 hrs to fix
    front/src/config/demo.js on lines 3568..3590

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

    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

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

          features: [
            {
              name: 'Battery',
              category: 'battery',
              type: 'integer',
    Severity: Major
    Found in front/src/config/demo.js and 1 other location - About 3 hrs to fix
    front/src/config/demo.js on lines 3636..3658

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

    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

        {
          id: '2',
          name: 'Right Bedside',
          type: 'Extended color light',
          model: 'LCT001',
    Severity: Major
    Found in front/src/config/demo.js and 1 other location - About 2 hrs to fix
    front/src/config/demo.js on lines 3427..3449

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

    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

        {
          id: '3',
          name: 'Left Bedside',
          type: 'Extended color light',
          model: 'LCT001',
    Severity: Major
    Found in front/src/config/demo.js and 1 other location - About 2 hrs to fix
    front/src/config/demo.js on lines 3404..3426

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

    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

        {
          id: 'fbedb47f-4d25-4381-8923-2633b23192a0',
          service_id: 'a810b8db-6d04-4697-bed3-c4b72c996279',
          room_id: 'cecc52c7-3e67-4b75-9b13-9a8867b0443d',
          name: 'TV Remote',
    Severity: Major
    Found in front/src/config/demo.js and 1 other location - About 2 hrs to fix
    front/src/config/demo.js on lines 1433..1450

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

    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

        {
          id: '197018ef-5110-4e3d-9022-cecb85fce5cb',
          service_id: 'a810b8db-6d04-4697-bed3-c4b72c996279',
          room_id: 'cecc52c7-3e67-4b75-9b13-9a8867b0443d',
          name: 'LED remote',
    Severity: Major
    Found in front/src/config/demo.js and 1 other location - About 2 hrs to fix
    front/src/config/demo.js on lines 1415..1432

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

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

      'post /api/v1/login': {
        id: '215811c9-c0aa-4148-8a4b-e02892d7446f',
        firstname: 'tony',
        lastname: 'Stark',
        email: 'tony.stark@gladysassistant.com',
    Severity: Major
    Found in front/src/config/demo.js and 2 other locations - About 1 hr to fix
    front/src/config/demo.js on lines 50..64
    front/src/config/demo.js on lines 65..79

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

      'post /api/v1/user': {
        id: '215811c9-c0aa-4148-8a4b-e02892d7446f',
        firstname: 'tony',
        lastname: 'Stark',
        email: 'tony.stark@gladysassistant.com',
    Severity: Major
    Found in front/src/config/demo.js and 2 other locations - About 1 hr to fix
    front/src/config/demo.js on lines 4..18
    front/src/config/demo.js on lines 65..79

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

      'patch /api/v1/user': {
        id: '215811c9-c0aa-4148-8a4b-e02892d7446f',
        firstname: 'tony',
        lastname: 'Stark',
        email: 'tony.stark@gladysassistant.com',
    Severity: Major
    Found in front/src/config/demo.js and 2 other locations - About 1 hr to fix
    front/src/config/demo.js on lines 4..18
    front/src/config/demo.js on lines 50..64

    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

        {
          id: '247b1dd0-6fab-47a8-a9c8-1405deae0ae8',
          sender_id: '0cd30aef-9c4e-4a23-88e3-3547971296e5',
          receiver_id: null,
          text: "What's the weather like?",
    Severity: Major
    Found in front/src/config/demo.js and 1 other location - About 1 hr to fix
    front/src/config/demo.js on lines 1031..1041

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

    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

        {
          id: '247b1dd0-6fab-47a8-a9c8-1405deae0ae8',
          sender_id: '0cd30aef-9c4e-4a23-88e3-3547971296e5',
          receiver_id: null,
          text: "What's the temperature in the kitchen?",
    Severity: Major
    Found in front/src/config/demo.js and 1 other location - About 1 hr to fix
    front/src/config/demo.js on lines 1009..1019

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

    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

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

        {
          name: 'SML c9',
          model: 'smlc9',
          external_id: 'bluetooth:0011223342',
          selector: 'bluetooth-0011223342',
    Severity: Major
    Found in front/src/config/demo.js and 1 other location - About 1 hr to fix
    front/src/config/demo.js on lines 3605..3621

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

    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

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

      'get /api/v1/service/bluetooth/peripheral/bluetooth-0011223342': {
        name: 'SML c9',
        model: 'smlc9',
        external_id: 'bluetooth:0011223342',
        selector: 'bluetooth-0011223342',
    Severity: Major
    Found in front/src/config/demo.js and 1 other location - About 1 hr to fix
    front/src/config/demo.js on lines 3533..3549

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

    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

        {
          name: 'Sonoff Basic Kitchen',
          external_id: 'tasmota:192.168.1.1',
          created_at: '2019-02-12T07:49:07.556Z',
          model: 'sonoff-basic',
    Severity: Major
    Found in front/src/config/demo.js and 1 other location - About 1 hr to fix
    front/src/config/demo.js on lines 1783..1800

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

    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

        {
          name: 'Switch',
          external_id: 'tasmota:192.168.1.1',
          selector: 'tasmota-192-168-1-1',
          room_id: 'cecc52c7-3e67-4b75-9b13-9a8867b0443e',
    Severity: Major
    Found in front/src/config/demo.js and 1 other location - About 1 hr to fix
    front/src/config/demo.js on lines 1883..1900

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

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

        {
          id: '210460b2-c9a8-4891-9cca-464c3e19bfbb',
          path: 'https://url-backup',
          size: 1013680,
          created_at: dayjs().subtract(3, 'day'),
    Severity: Major
    Found in front/src/config/demo.js and 2 other locations - About 1 hr to fix
    front/src/config/demo.js on lines 1982..1989
    front/src/config/demo.js on lines 1990..1997

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

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

        {
          id: '99fac564-0844-44f6-866b-2b8dcf0d76eb',
          path: 'https://url-backup',
          size: 2024000100,
          created_at: dayjs().subtract(1, 'day'),
    Severity: Major
    Found in front/src/config/demo.js and 2 other locations - About 1 hr to fix
    front/src/config/demo.js on lines 1990..1997
    front/src/config/demo.js on lines 1998..2005

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

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

        {
          id: '99fac564-0844-44f6-866b-2b8dcf0d76eb',
          path: 'https://url-backup',
          size: 1127680,
          created_at: dayjs().subtract(2, 'day'),
    Severity: Major
    Found in front/src/config/demo.js and 2 other locations - About 1 hr to fix
    front/src/config/demo.js on lines 1982..1989
    front/src/config/demo.js on lines 1998..2005

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

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

      'get /api/v1/device/tasmota-sonoff-basic': {
        name: 'Switch',
        external_id: 'tasmota:sonoff-basic',
        selector: 'sonoff-basic',
        room_id: 'cecc52c7-3e67-4b75-9b13-9a8867b0443d',
    Severity: Major
    Found in front/src/config/demo.js and 2 other locations - About 55 mins to fix
    front/src/config/demo.js on lines 1816..1829
    front/src/config/demo.js on lines 1830..1843

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

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

      'get /api/v1/device/tasmota-192-168-1-1': {
        name: 'Switch',
        external_id: 'tasmota:sonoff-basic',
        selector: 'sonoff-basic',
        room_id: 'cecc52c7-3e67-4b75-9b13-9a8867b0443d',
    Severity: Major
    Found in front/src/config/demo.js and 2 other locations - About 55 mins to fix
    front/src/config/demo.js on lines 1802..1815
    front/src/config/demo.js on lines 1816..1829

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

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

      'get /api/v1/device/zigbee2mqtt-0x00158d0005828ece': {
        name: 'Aqara Sensor',
        external_id: 'zigbee2mqtt-0x00158d0005828ece',
        selector: 'zigbee2mqtt-0x00158d0005828ece',
        room_id: 'cecc52c7-3e67-4b75-9b13-9a8867b0443d',
    Severity: Major
    Found in front/src/config/demo.js and 2 other locations - About 55 mins to fix
    front/src/config/demo.js on lines 1802..1815
    front/src/config/demo.js on lines 1830..1843

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

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

          features: [
            {
              name: 'sp2',
              category: 'switch',
              type: 'binary',
    Severity: Major
    Found in front/src/config/demo.js and 4 other locations - About 55 mins to fix
    front/cypress/e2e/routes/integration/broadlink/devices/BroadlinkDeviceList.cy.js on lines 15..27
    front/cypress/e2e/routes/integration/broadlink/devices/BroadlinkEditRemote.cy.js on lines 17..29
    front/cypress/e2e/routes/integration/broadlink/devices/BroadlinkEditRemoteSkipAll.cy.js on lines 17..29
    front/src/config/demo.js on lines 1392..1404

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

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

            features: [
              {
                name: 'SP2',
                category: 'switch',
                type: 'binary',
    Severity: Major
    Found in front/src/config/demo.js and 4 other locations - About 55 mins to fix
    front/cypress/e2e/routes/integration/broadlink/devices/BroadlinkDeviceList.cy.js on lines 15..27
    front/cypress/e2e/routes/integration/broadlink/devices/BroadlinkEditRemote.cy.js on lines 17..29
    front/cypress/e2e/routes/integration/broadlink/devices/BroadlinkEditRemoteSkipAll.cy.js on lines 17..29
    front/src/config/demo.js on lines 1468..1480

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

    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

        {
          id: 'b2d590aa-40d7-435a-910a-cf370dde06a9',
          type: 'daily-device-state-aggregate',
          status: 'success',
          progress: 98,
    Severity: Major
    Found in front/src/config/demo.js and 8 other locations - About 50 mins to fix
    front/src/config/demo.js on lines 4021..4030
    front/src/config/demo.js on lines 4041..4050
    front/src/config/demo.js on lines 4051..4060
    front/src/config/demo.js on lines 4061..4070
    front/src/config/demo.js on lines 4071..4080
    front/src/config/demo.js on lines 4081..4090
    front/src/config/demo.js on lines 4091..4100
    front/src/config/demo.js on lines 4101..4110

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

    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

        {
          id: 'd1e7ee47-229c-4b9f-bbaa-201db860cc25',
          type: 'hourly-device-state-aggregate',
          status: 'success',
          progress: 100,
    Severity: Major
    Found in front/src/config/demo.js and 8 other locations - About 50 mins to fix
    front/src/config/demo.js on lines 4021..4030
    front/src/config/demo.js on lines 4031..4040
    front/src/config/demo.js on lines 4051..4060
    front/src/config/demo.js on lines 4061..4070
    front/src/config/demo.js on lines 4071..4080
    front/src/config/demo.js on lines 4081..4090
    front/src/config/demo.js on lines 4091..4100
    front/src/config/demo.js on lines 4101..4110

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

    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

        {
          id: 'f69252f4-1216-4021-8fc0-83234da71a4a',
          type: 'monthly-device-state-aggregate',
          status: 'success',
          progress: 100,
    Severity: Major
    Found in front/src/config/demo.js and 8 other locations - About 50 mins to fix
    front/src/config/demo.js on lines 4031..4040
    front/src/config/demo.js on lines 4041..4050
    front/src/config/demo.js on lines 4051..4060
    front/src/config/demo.js on lines 4061..4070
    front/src/config/demo.js on lines 4071..4080
    front/src/config/demo.js on lines 4081..4090
    front/src/config/demo.js on lines 4091..4100
    front/src/config/demo.js on lines 4101..4110

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

    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

        {
          id: '10469873-569a-4dfb-b35c-4468c26542a4',
          type: 'daily-device-state-aggregate',
          status: 'success',
          progress: 100,
    Severity: Major
    Found in front/src/config/demo.js and 8 other locations - About 50 mins to fix
    front/src/config/demo.js on lines 4021..4030
    front/src/config/demo.js on lines 4031..4040
    front/src/config/demo.js on lines 4041..4050
    front/src/config/demo.js on lines 4051..4060
    front/src/config/demo.js on lines 4071..4080
    front/src/config/demo.js on lines 4081..4090
    front/src/config/demo.js on lines 4091..4100
    front/src/config/demo.js on lines 4101..4110

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

    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

        {
          id: '5ca896b5-e810-48f5-bfb6-f3039a6776c5',
          type: 'daily-device-state-aggregate',
          status: 'success',
          progress: 100,
    Severity: Major
    Found in front/src/config/demo.js and 8 other locations - About 50 mins to fix
    front/src/config/demo.js on lines 4021..4030
    front/src/config/demo.js on lines 4031..4040
    front/src/config/demo.js on lines 4041..4050
    front/src/config/demo.js on lines 4051..4060
    front/src/config/demo.js on lines 4061..4070
    front/src/config/demo.js on lines 4071..4080
    front/src/config/demo.js on lines 4081..4090
    front/src/config/demo.js on lines 4101..4110

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

    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

        {
          id: 'ae916efe-6209-49cb-a2fc-323f3ab5f91d',
          type: 'hourly-device-state-aggregate',
          status: 'success',
          progress: 100,
    Severity: Major
    Found in front/src/config/demo.js and 8 other locations - About 50 mins to fix
    front/src/config/demo.js on lines 4021..4030
    front/src/config/demo.js on lines 4031..4040
    front/src/config/demo.js on lines 4041..4050
    front/src/config/demo.js on lines 4051..4060
    front/src/config/demo.js on lines 4061..4070
    front/src/config/demo.js on lines 4071..4080
    front/src/config/demo.js on lines 4081..4090
    front/src/config/demo.js on lines 4091..4100

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

    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

        {
          id: '5307b306-8d95-41e3-9ec6-a5c29d386c9b',
          type: 'hourly-device-state-aggregate',
          status: 'success',
          progress: 100,
    Severity: Major
    Found in front/src/config/demo.js and 8 other locations - About 50 mins to fix
    front/src/config/demo.js on lines 4021..4030
    front/src/config/demo.js on lines 4031..4040
    front/src/config/demo.js on lines 4041..4050
    front/src/config/demo.js on lines 4051..4060
    front/src/config/demo.js on lines 4061..4070
    front/src/config/demo.js on lines 4081..4090
    front/src/config/demo.js on lines 4091..4100
    front/src/config/demo.js on lines 4101..4110

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

    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

        {
          id: 'c3da516f-3565-4b00-be82-ddd00fe39a12',
          type: 'monthly-device-state-aggregate',
          status: 'success',
          progress: 100,
    Severity: Major
    Found in front/src/config/demo.js and 8 other locations - About 50 mins to fix
    front/src/config/demo.js on lines 4021..4030
    front/src/config/demo.js on lines 4031..4040
    front/src/config/demo.js on lines 4041..4050
    front/src/config/demo.js on lines 4051..4060
    front/src/config/demo.js on lines 4061..4070
    front/src/config/demo.js on lines 4071..4080
    front/src/config/demo.js on lines 4091..4100
    front/src/config/demo.js on lines 4101..4110

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

    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

        {
          id: '06411e01-a909-4531-9246-2e935c16ba69',
          type: 'monthly-device-state-aggregate',
          status: 'success',
          progress: 100,
    Severity: Major
    Found in front/src/config/demo.js and 8 other locations - About 50 mins to fix
    front/src/config/demo.js on lines 4021..4030
    front/src/config/demo.js on lines 4031..4040
    front/src/config/demo.js on lines 4041..4050
    front/src/config/demo.js on lines 4061..4070
    front/src/config/demo.js on lines 4071..4080
    front/src/config/demo.js on lines 4081..4090
    front/src/config/demo.js on lines 4091..4100
    front/src/config/demo.js on lines 4101..4110

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

    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

            {
              category: 'battery',
              external_id: 'zigbee2mqtt:0x00158d00033e88d5:battery:integer:battery',
              has_feedback: false,
              max: 100,
    Severity: Minor
    Found in front/src/config/demo.js and 1 other location - About 50 mins to fix
    front/src/config/demo.js on lines 1699..1710

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

    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

            {
              category: 'switch',
              external_id: 'zigbee2mqtt:0x00158d00033e88d5:switch:voltage:voltage',
              has_feedback: false,
              max: 10000,
    Severity: Minor
    Found in front/src/config/demo.js and 1 other location - About 50 mins to fix
    front/src/config/demo.js on lines 1675..1686

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

    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

      'get /api/v1/service/zigbee2mqtt/status': {
        usbConfigured: true,
        mqttExist: true,
        mqttRunning: true,
        zigbee2mqttExist: true,
    Severity: Minor
    Found in front/src/config/demo.js and 1 other location - About 50 mins to fix
    front/src/routes/integration/all/zigbee2mqtt/setup-page/actions.js on lines 14..25

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

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

        {
          id: '2367a8cf-47a8-4db7-83b0-f89c2c6c34ac',
          token_type: 'refresh_token',
          scope: ['dashboard:write', 'dashboard:read'],
          valid_until: '2019-07-26T00:29:00.783Z',
    Severity: Major
    Found in front/src/config/demo.js and 2 other locations - About 45 mins to fix
    front/src/config/demo.js on lines 2294..2305
    front/src/config/demo.js on lines 2318..2329

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

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

        {
          id: '4b249694-661b-4c48-afb5-924bbedcee63',
          token_type: 'refresh_token',
          scope: ['dashboard:write', 'dashboard:read'],
          valid_until: '2019-07-26T01:00:50.137Z',
    Severity: Major
    Found in front/src/config/demo.js and 2 other locations - About 45 mins to fix
    front/src/config/demo.js on lines 2306..2317
    front/src/config/demo.js on lines 2318..2329

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

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

        {
          id: '2367a8cf-47a8-4db7-83b0-f89c2c6c34ac',
          token_type: 'refresh_token',
          scope: ['dashboard:write', 'dashboard:read'],
          valid_until: '2019-07-26T00:29:00.783Z',
    Severity: Major
    Found in front/src/config/demo.js and 2 other locations - About 45 mins to fix
    front/src/config/demo.js on lines 2294..2305
    front/src/config/demo.js on lines 2306..2317

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

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

        {
          id: '4cd73c14-a929-4af0-a5e2-baed35802224',
          pod_id: null,
          name: 'rtsp-camera',
          selector: 'rtsp-camera',
    Severity: Major
    Found in front/src/config/demo.js and 16 other locations - About 35 mins to fix
    front/src/config/demo.js on lines 2116..2126
    front/src/config/demo.js on lines 2127..2137
    front/src/config/demo.js on lines 2149..2159
    front/src/config/demo.js on lines 2160..2170
    front/src/config/demo.js on lines 2171..2181
    front/src/config/demo.js on lines 2182..2192
    front/src/config/demo.js on lines 2193..2203
    front/src/config/demo.js on lines 2204..2214
    front/src/config/demo.js on lines 2215..2225
    front/src/config/demo.js on lines 2226..2236
    front/src/config/demo.js on lines 2237..2247
    front/src/config/demo.js on lines 2248..2258
    front/src/config/demo.js on lines 2259..2269
    front/src/config/demo.js on lines 2270..2280
    front/src/config/demo.js on lines 2281..2291
    front/src/config/demo.js on lines 3758..3768

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

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

        {
          id: '40262062-2e71-412c-8da0-70bd03f03b90',
          pod_id: null,
          name: 'philips-hue',
          selector: 'philips-hue',
    Severity: Major
    Found in front/src/config/demo.js and 16 other locations - About 35 mins to fix
    front/src/config/demo.js on lines 2116..2126
    front/src/config/demo.js on lines 2138..2148
    front/src/config/demo.js on lines 2149..2159
    front/src/config/demo.js on lines 2160..2170
    front/src/config/demo.js on lines 2171..2181
    front/src/config/demo.js on lines 2182..2192
    front/src/config/demo.js on lines 2193..2203
    front/src/config/demo.js on lines 2204..2214
    front/src/config/demo.js on lines 2215..2225
    front/src/config/demo.js on lines 2226..2236
    front/src/config/demo.js on lines 2237..2247
    front/src/config/demo.js on lines 2248..2258
    front/src/config/demo.js on lines 2259..2269
    front/src/config/demo.js on lines 2270..2280
    front/src/config/demo.js on lines 2281..2291
    front/src/config/demo.js on lines 3758..3768

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

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

        {
          id: '27c96cfe-98ce-437b-a83f-5b13e0605203',
          pod_id: null,
          name: 'example',
          selector: 'example',
    Severity: Major
    Found in front/src/config/demo.js and 16 other locations - About 35 mins to fix
    front/src/config/demo.js on lines 2127..2137
    front/src/config/demo.js on lines 2138..2148
    front/src/config/demo.js on lines 2149..2159
    front/src/config/demo.js on lines 2160..2170
    front/src/config/demo.js on lines 2171..2181
    front/src/config/demo.js on lines 2182..2192
    front/src/config/demo.js on lines 2193..2203
    front/src/config/demo.js on lines 2204..2214
    front/src/config/demo.js on lines 2215..2225
    front/src/config/demo.js on lines 2226..2236
    front/src/config/demo.js on lines 2237..2247
    front/src/config/demo.js on lines 2248..2258
    front/src/config/demo.js on lines 2259..2269
    front/src/config/demo.js on lines 2270..2280
    front/src/config/demo.js on lines 2281..2291
    front/src/config/demo.js on lines 3758..3768

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

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

        {
          id: 'c9fe2705-35dc-417b-b6fc-c4bbb9c69886',
          pod_id: null,
          name: 'tp-link',
          selector: 'tp-link',
    Severity: Major
    Found in front/src/config/demo.js and 16 other locations - About 35 mins to fix
    front/src/config/demo.js on lines 2116..2126
    front/src/config/demo.js on lines 2127..2137
    front/src/config/demo.js on lines 2138..2148
    front/src/config/demo.js on lines 2149..2159
    front/src/config/demo.js on lines 2160..2170
    front/src/config/demo.js on lines 2171..2181
    front/src/config/demo.js on lines 2182..2192
    front/src/config/demo.js on lines 2193..2203
    front/src/config/demo.js on lines 2204..2214
    front/src/config/demo.js on lines 2215..2225
    front/src/config/demo.js on lines 2226..2236
    front/src/config/demo.js on lines 2237..2247
    front/src/config/demo.js on lines 2248..2258
    front/src/config/demo.js on lines 2259..2269
    front/src/config/demo.js on lines 2281..2291
    front/src/config/demo.js on lines 3758..3768

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

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

        {
          id: '39a278e9-66da-47cb-bdaa-264ba6418091',
          pod_id: null,
          name: 'openweather',
          selector: 'openweather',
    Severity: Major
    Found in front/src/config/demo.js and 16 other locations - About 35 mins to fix
    front/src/config/demo.js on lines 2116..2126
    front/src/config/demo.js on lines 2127..2137
    front/src/config/demo.js on lines 2138..2148
    front/src/config/demo.js on lines 2149..2159
    front/src/config/demo.js on lines 2160..2170
    front/src/config/demo.js on lines 2171..2181
    front/src/config/demo.js on lines 2182..2192
    front/src/config/demo.js on lines 2193..2203
    front/src/config/demo.js on lines 2204..2214
    front/src/config/demo.js on lines 2215..2225
    front/src/config/demo.js on lines 2226..2236
    front/src/config/demo.js on lines 2248..2258
    front/src/config/demo.js on lines 2259..2269
    front/src/config/demo.js on lines 2270..2280
    front/src/config/demo.js on lines 2281..2291
    front/src/config/demo.js on lines 3758..3768

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

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

        {
          id: '6d3c7a63-e4b8-4650-bcd3-50cf42b2996f',
          pod_id: null,
          name: 'caldav',
          selector: 'caldav',
    Severity: Major
    Found in front/src/config/demo.js and 16 other locations - About 35 mins to fix
    front/src/config/demo.js on lines 2116..2126
    front/src/config/demo.js on lines 2127..2137
    front/src/config/demo.js on lines 2138..2148
    front/src/config/demo.js on lines 2149..2159
    front/src/config/demo.js on lines 2160..2170
    front/src/config/demo.js on lines 2171..2181
    front/src/config/demo.js on lines 2182..2192
    front/src/config/demo.js on lines 2193..2203
    front/src/config/demo.js on lines 2204..2214
    front/src/config/demo.js on lines 2215..2225
    front/src/config/demo.js on lines 2237..2247
    front/src/config/demo.js on lines 2248..2258
    front/src/config/demo.js on lines 2259..2269
    front/src/config/demo.js on lines 2270..2280
    front/src/config/demo.js on lines 2281..2291
    front/src/config/demo.js on lines 3758..3768

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

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

        {
          id: 'd97ba3fa-872f-4ecc-879f-46c55a2930c6',
          pod_id: null,
          name: 'google-actions',
          selector: 'google-actions',
    Severity: Major
    Found in front/src/config/demo.js and 16 other locations - About 35 mins to fix
    front/src/config/demo.js on lines 2116..2126
    front/src/config/demo.js on lines 2127..2137
    front/src/config/demo.js on lines 2138..2148
    front/src/config/demo.js on lines 2149..2159
    front/src/config/demo.js on lines 2160..2170
    front/src/config/demo.js on lines 2171..2181
    front/src/config/demo.js on lines 2182..2192
    front/src/config/demo.js on lines 2193..2203
    front/src/config/demo.js on lines 2204..2214
    front/src/config/demo.js on lines 2226..2236
    front/src/config/demo.js on lines 2237..2247
    front/src/config/demo.js on lines 2248..2258
    front/src/config/demo.js on lines 2259..2269
    front/src/config/demo.js on lines 2270..2280
    front/src/config/demo.js on lines 2281..2291
    front/src/config/demo.js on lines 3758..3768

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

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

        {
          id: '2e0bc58b-11e2-4176-8ad3-9ebc8cdd2318',
          pod_id: null,
          name: 'mqtt',
          selector: 'mqtt',
    Severity: Major
    Found in front/src/config/demo.js and 16 other locations - About 35 mins to fix
    front/src/config/demo.js on lines 2116..2126
    front/src/config/demo.js on lines 2127..2137
    front/src/config/demo.js on lines 2138..2148
    front/src/config/demo.js on lines 2149..2159
    front/src/config/demo.js on lines 2160..2170
    front/src/config/demo.js on lines 2171..2181
    front/src/config/demo.js on lines 2182..2192
    front/src/config/demo.js on lines 2193..2203
    front/src/config/demo.js on lines 2215..2225
    front/src/config/demo.js on lines 2226..2236
    front/src/config/demo.js on lines 2237..2247
    front/src/config/demo.js on lines 2248..2258
    front/src/config/demo.js on lines 2259..2269
    front/src/config/demo.js on lines 2270..2280
    front/src/config/demo.js on lines 2281..2291
    front/src/config/demo.js on lines 3758..3768

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

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

        {
          id: '09a3e250-940a-4f52-8595-e6268ffd7198',
          pod_id: null,
          name: 'usb',
          selector: 'usb',
    Severity: Major
    Found in front/src/config/demo.js and 16 other locations - About 35 mins to fix
    front/src/config/demo.js on lines 2116..2126
    front/src/config/demo.js on lines 2127..2137
    front/src/config/demo.js on lines 2138..2148
    front/src/config/demo.js on lines 2149..2159
    front/src/config/demo.js on lines 2171..2181
    front/src/config/demo.js on lines 2182..2192
    front/src/config/demo.js on lines 2193..2203
    front/src/config/demo.js on lines 2204..2214
    front/src/config/demo.js on lines 2215..2225
    front/src/config/demo.js on lines 2226..2236
    front/src/config/demo.js on lines 2237..2247
    front/src/config/demo.js on lines 2248..2258
    front/src/config/demo.js on lines 2259..2269
    front/src/config/demo.js on lines 2270..2280
    front/src/config/demo.js on lines 2281..2291
    front/src/config/demo.js on lines 3758..3768

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

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

        {
          id: '3772bbf5-b1d7-441f-9bd4-ef94920e31cd',
          pod_id: null,
          name: 'zwave',
          selector: 'zwave',
    Severity: Major
    Found in front/src/config/demo.js and 16 other locations - About 35 mins to fix
    front/src/config/demo.js on lines 2116..2126
    front/src/config/demo.js on lines 2127..2137
    front/src/config/demo.js on lines 2138..2148
    front/src/config/demo.js on lines 2149..2159
    front/src/config/demo.js on lines 2160..2170
    front/src/config/demo.js on lines 2171..2181
    front/src/config/demo.js on lines 2193..2203
    front/src/config/demo.js on lines 2204..2214
    front/src/config/demo.js on lines 2215..2225
    front/src/config/demo.js on lines 2226..2236
    front/src/config/demo.js on lines 2237..2247
    front/src/config/demo.js on lines 2248..2258
    front/src/config/demo.js on lines 2259..2269
    front/src/config/demo.js on lines 2270..2280
    front/src/config/demo.js on lines 2281..2291
    front/src/config/demo.js on lines 3758..3768

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

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

        {
          id: '9682e167-e07f-4823-bd31-a60f957842e0',
          pod_id: null,
          name: 'broadlink',
          selector: 'broadlink',
    Severity: Major
    Found in front/src/config/demo.js and 16 other locations - About 35 mins to fix
    front/src/config/demo.js on lines 2116..2126
    front/src/config/demo.js on lines 2127..2137
    front/src/config/demo.js on lines 2138..2148
    front/src/config/demo.js on lines 2149..2159
    front/src/config/demo.js on lines 2160..2170
    front/src/config/demo.js on lines 2171..2181
    front/src/config/demo.js on lines 2182..2192
    front/src/config/demo.js on lines 2193..2203
    front/src/config/demo.js on lines 2204..2214
    front/src/config/demo.js on lines 2215..2225
    front/src/config/demo.js on lines 2226..2236
    front/src/config/demo.js on lines 2237..2247
    front/src/config/demo.js on lines 2259..2269
    front/src/config/demo.js on lines 2270..2280
    front/src/config/demo.js on lines 2281..2291
    front/src/config/demo.js on lines 3758..3768

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

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

        {
          id: '366fd9d7-bfbf-4c13-bd8c-4cc777799142',
          pod_id: null,
          name: 'xiaomi',
          selector: 'xiaomi',
    Severity: Major
    Found in front/src/config/demo.js and 16 other locations - About 35 mins to fix
    front/src/config/demo.js on lines 2116..2126
    front/src/config/demo.js on lines 2127..2137
    front/src/config/demo.js on lines 2138..2148
    front/src/config/demo.js on lines 2149..2159
    front/src/config/demo.js on lines 2160..2170
    front/src/config/demo.js on lines 2182..2192
    front/src/config/demo.js on lines 2193..2203
    front/src/config/demo.js on lines 2204..2214
    front/src/config/demo.js on lines 2215..2225
    front/src/config/demo.js on lines 2226..2236
    front/src/config/demo.js on lines 2237..2247
    front/src/config/demo.js on lines 2248..2258
    front/src/config/demo.js on lines 2259..2269
    front/src/config/demo.js on lines 2270..2280
    front/src/config/demo.js on lines 2281..2291
    front/src/config/demo.js on lines 3758..3768

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

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

        {
          id: 'd1af258c-2016-4dc9-b0cc-d2e92dd2fcec',
          pod_id: null,
          name: 'lan-manager',
          selector: 'lan-manager',
    Severity: Major
    Found in front/src/config/demo.js and 16 other locations - About 35 mins to fix
    front/src/config/demo.js on lines 2116..2126
    front/src/config/demo.js on lines 2127..2137
    front/src/config/demo.js on lines 2138..2148
    front/src/config/demo.js on lines 2149..2159
    front/src/config/demo.js on lines 2160..2170
    front/src/config/demo.js on lines 2171..2181
    front/src/config/demo.js on lines 2182..2192
    front/src/config/demo.js on lines 2193..2203
    front/src/config/demo.js on lines 2204..2214
    front/src/config/demo.js on lines 2215..2225
    front/src/config/demo.js on lines 2226..2236
    front/src/config/demo.js on lines 2237..2247
    front/src/config/demo.js on lines 2248..2258
    front/src/config/demo.js on lines 2259..2269
    front/src/config/demo.js on lines 2270..2280
    front/src/config/demo.js on lines 3758..3768

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

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

        {
          id: '0c27de72-ced7-4f7f-8950-473b9e904e71',
          pod_id: null,
          name: 'telegram',
          selector: 'telegram',
    Severity: Major
    Found in front/src/config/demo.js and 16 other locations - About 35 mins to fix
    front/src/config/demo.js on lines 2116..2126
    front/src/config/demo.js on lines 2127..2137
    front/src/config/demo.js on lines 2138..2148
    front/src/config/demo.js on lines 2160..2170
    front/src/config/demo.js on lines 2171..2181
    front/src/config/demo.js on lines 2182..2192
    front/src/config/demo.js on lines 2193..2203
    front/src/config/demo.js on lines 2204..2214
    front/src/config/demo.js on lines 2215..2225
    front/src/config/demo.js on lines 2226..2236
    front/src/config/demo.js on lines 2237..2247
    front/src/config/demo.js on lines 2248..2258
    front/src/config/demo.js on lines 2259..2269
    front/src/config/demo.js on lines 2270..2280
    front/src/config/demo.js on lines 2281..2291
    front/src/config/demo.js on lines 3758..3768

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

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

        {
          id: '7355bc7f-4109-40ba-819f-fb03f91969b0',
          pod_id: null,
          name: 'tasmota',
          selector: 'tasmota',
    Severity: Major
    Found in front/src/config/demo.js and 16 other locations - About 35 mins to fix
    front/src/config/demo.js on lines 2116..2126
    front/src/config/demo.js on lines 2127..2137
    front/src/config/demo.js on lines 2138..2148
    front/src/config/demo.js on lines 2149..2159
    front/src/config/demo.js on lines 2160..2170
    front/src/config/demo.js on lines 2171..2181
    front/src/config/demo.js on lines 2182..2192
    front/src/config/demo.js on lines 2204..2214
    front/src/config/demo.js on lines 2215..2225
    front/src/config/demo.js on lines 2226..2236
    front/src/config/demo.js on lines 2237..2247
    front/src/config/demo.js on lines 2248..2258
    front/src/config/demo.js on lines 2259..2269
    front/src/config/demo.js on lines 2270..2280
    front/src/config/demo.js on lines 2281..2291
    front/src/config/demo.js on lines 3758..3768

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

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

        {
          id: 'd6ea610f-1e33-4c08-89a3-1c8be2cc45f9',
          pod_id: null,
          name: 'bluetooth',
          selector: 'bluetooth',
    Severity: Major
    Found in front/src/config/demo.js and 16 other locations - About 35 mins to fix
    front/src/config/demo.js on lines 2116..2126
    front/src/config/demo.js on lines 2127..2137
    front/src/config/demo.js on lines 2138..2148
    front/src/config/demo.js on lines 2149..2159
    front/src/config/demo.js on lines 2160..2170
    front/src/config/demo.js on lines 2171..2181
    front/src/config/demo.js on lines 2182..2192
    front/src/config/demo.js on lines 2193..2203
    front/src/config/demo.js on lines 2204..2214
    front/src/config/demo.js on lines 2215..2225
    front/src/config/demo.js on lines 2226..2236
    front/src/config/demo.js on lines 2237..2247
    front/src/config/demo.js on lines 2248..2258
    front/src/config/demo.js on lines 2270..2280
    front/src/config/demo.js on lines 2281..2291
    front/src/config/demo.js on lines 3758..3768

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

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

      'get /api/v1/service/tp-link': {
        id: 'c9fe2705-35dc-417b-b6fc-c4bbb9c69886',
        pod_id: null,
        name: 'tp-link',
        selector: 'tp-link',
    Severity: Major
    Found in front/src/config/demo.js and 16 other locations - About 35 mins to fix
    front/src/config/demo.js on lines 2116..2126
    front/src/config/demo.js on lines 2127..2137
    front/src/config/demo.js on lines 2138..2148
    front/src/config/demo.js on lines 2149..2159
    front/src/config/demo.js on lines 2160..2170
    front/src/config/demo.js on lines 2171..2181
    front/src/config/demo.js on lines 2182..2192
    front/src/config/demo.js on lines 2193..2203
    front/src/config/demo.js on lines 2204..2214
    front/src/config/demo.js on lines 2215..2225
    front/src/config/demo.js on lines 2226..2236
    front/src/config/demo.js on lines 2237..2247
    front/src/config/demo.js on lines 2248..2258
    front/src/config/demo.js on lines 2259..2269
    front/src/config/demo.js on lines 2270..2280
    front/src/config/demo.js on lines 2281..2291

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

    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

      'get /api/v1/user/tony': {
        id: 'd84ced32-d937-4cf6-a32e-105ffb584226',
        firstname: 'Tony',
        lastname: 'Stark',
        selector: 'tony',
    Severity: Minor
    Found in front/src/config/demo.js and 1 other location - About 35 mins to fix
    front/src/config/demo.js on lines 1087..1096

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

    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

      'get /api/v1/user/pepper': {
        id: 'd84ced32-d937-4cf6-a32e-105ffb584226',
        firstname: 'Pepper',
        lastname: 'Pots',
        selector: 'pepper',
    Severity: Minor
    Found in front/src/config/demo.js and 1 other location - About 35 mins to fix
    front/src/config/demo.js on lines 1077..1086

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

    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

      'get /api/v1/service/philips-hue/light': [
        {
          id: '1',
          name: 'New Lamp',
          model: 'LCT007',
    Severity: Minor
    Found in front/src/config/demo.js and 1 other location - About 35 mins to fix
    server/seeders/20231002113233-tag-scene.js on lines 5..18

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

    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

        {
          name: 'Sonos Speaker',
          external_id: 'sonos:uuid',
          features: [
            {
    Severity: Minor
    Found in front/src/config/demo.js and 1 other location - About 30 mins to fix
    front/src/config/demo.js on lines 4142..4154

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

    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

        {
          name: 'Sonos Speaker',
          external_id: 'sonos:another_uuid',
          features: [
            {
    Severity: Minor
    Found in front/src/config/demo.js and 1 other location - About 30 mins to fix
    front/src/config/demo.js on lines 4129..4141

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

    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