Skip to content

Commit d5daa92

Browse files
committed
rectacoring
Signed-off-by: AndrewFG <[email protected]>
1 parent 5214ab0 commit d5daa92

File tree

1 file changed

+4
-4
lines changed
  • bundles/org.openhab.binding.govee/src/main/java/org/openhab/binding/govee/internal

1 file changed

+4
-4
lines changed

bundles/org.openhab.binding.govee/src/main/java/org/openhab/binding/govee/internal/GoveeHandler.java

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -263,10 +263,10 @@ private void sendKelvin(int kelvin) throws IOException {
263263
* @return the HSB presentation state
264264
*/
265265
private static HSBType buildHSB(Color normalColor, int brightness, boolean on) {
266-
int[] normalizedRGB = { normalColor.r(), normalColor.g(), normalColor.b() };
267-
HSBType normalizedHSB = ColorUtil.rgbToHsb(normalizedRGB);
268-
PercentType brightnessParam = on ? new PercentType(brightness) : PercentType.ZERO;
269-
return new HSBType(normalizedHSB.getHue(), normalizedHSB.getSaturation(), brightnessParam);
266+
int[] normalRGB = { normalColor.r(), normalColor.g(), normalColor.b() };
267+
HSBType normalHSB = ColorUtil.rgbToHsb(normalRGB);
268+
PercentType brightnessPercent = on ? new PercentType(brightness) : PercentType.ZERO;
269+
return new HSBType(normalHSB.getHue(), normalHSB.getSaturation(), brightnessPercent);
270270
}
271271

272272
void handleIncomingStatus(String response) {

0 commit comments

Comments
 (0)