1
0
mirror of https://github.com/oliexdev/openScale.git synced 2025-08-16 21:54:05 +02:00

Fix bodyfat calculation for 1byone (#741)

Adjust the value of bodyVar instead of replacing bodyVar with the adjustment factor.
This commit is contained in:
lbdroid
2021-08-21 12:01:16 -04:00
committed by GitHub
parent 4b451e40b7
commit 5183278432

View File

@@ -236,19 +236,19 @@ public class OneByoneLib {
if (sex != 0) { if (sex != 0) {
if (61.0f > weight) { if (61.0f > weight) {
bodyVar = 0.98f; bodyVar *= 0.98f;
} }
} else { } else {
if (50.0f > weight) { if (50.0f > weight) {
bodyVar = 1.02f; bodyVar *= 1.02f;
} }
if (weight > 60.0f) { if (weight > 60.0f) {
bodyVar = 0.96f; bodyVar *= 0.96f;
} }
if (height > 160.0f) { if (height > 160.0f) {
bodyVar = 1.03f; bodyVar *= 1.03f;
} }
} }