Skip to content

Commit d115ef6

Browse files
committed
fix copilot suggestions
Signed-off-by: Andrew Fiddian-Green <software@whitebear.ch>
1 parent e97fddb commit d115ef6

1 file changed

Lines changed: 4 additions & 4 deletions

File tree

  • bundles/org.openhab.core/src/main/java/org/openhab/core/util

bundles/org.openhab.core/src/main/java/org/openhab/core/util/LightModel.java

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -101,8 +101,8 @@
101101
* Kelvin). Where color temperature PercentType values are internally converted to Mired values on the percentage scale
102102
* between the configured {@link #coolestMired} and {@link #warmestMired} Mired values, and vice versa.</li>
103103
*
104-
* the color temperature changes then the HS values are adapted to match the corresponding color temperature point on
105-
* the Planckian Locus in the CIE color chart.</li>
104+
* <li>When the color temperature changes then the HS values are adapted to match the corresponding color temperature
105+
* point on the Planckian Locus in the CIE color chart.</li>
106106
*
107107
* <li>It handles input/output values in RGB format in the range [0..255]. The behavior depends on the
108108
* {@link #rgbLinkedToBrightness} setting. If {@link #rgbLinkedToBrightness} is true the RGB values read/write all three
@@ -293,7 +293,7 @@ public class LightModel {
293293
* <li>{@link #warmestMired} is 500 (the 'warmest' white color temperature)</li>
294294
* <li>{@link #coolestMired} is 153 (the 'coolest' white color temperature)</li>
295295
* <li>{@link #stepSize} is 10.0 (the step size for IncreaseDecreaseType commands)</li>
296-
* <li>{@link #warmBias} is 0,5 (the bias for warm white in RGBCW mode)</li>
296+
* <li>{@link #warmBias} is 0.5 (the bias for warm white in RGBCW mode)</li>
297297
* </ul>
298298
*/
299299
public LightModel() {
@@ -851,7 +851,7 @@ public void setMired(double mired) throws IllegalArgumentException {
851851
"Mired value '%f' out of range [%f..%f]".formatted(mired, coolestMired, warmestMired));
852852
}
853853
if (!Double.isNaN(mired)) { // don't update color if Mired is not known
854-
HSBType hsb = ColorUtil.xyToHsb(ColorUtil.kelvinToXY(1000000 / cachedMired));
854+
HSBType hsb = ColorUtil.xyToHsb(ColorUtil.kelvinToXY(1000000 / mired));
855855
cachedHSB = new HSBType(hsb.getHue(), hsb.getSaturation(), cachedHSB.getBrightness());
856856
}
857857
cachedMired = mired;

0 commit comments

Comments
 (0)