GladysProject/Gladys

View on GitHub
server/services/xiaomi/lib/commands/xiaomi.setValue.js

Summary

Maintainability
A
1 hr
Test Coverage

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

function setValue(device, deviceFeature, state) {
  logger.debug(`Xiaomi.setValue : Setting value of device ${device.external_id}`);
  let msg;
  const rgb = hslToRgb(214, 1, 0.5);
  const rgbNumber = 0xff000000 + (rgb[0] << 16) + (rgb[1] << 8) + rgb[2]; // eslint-disable-line no-bitwise
Severity: Minor
Found in server/services/xiaomi/lib/commands/xiaomi.setValue.js - About 1 hr to fix

    There are no issues that match your filters.

    Category
    Status