fix sleep goal and step goal not being set in database (should fix user attribute table spamming)

This commit is contained in:
Andreas Shimokawa 2016-09-11 12:35:26 +02:00
parent 0cc95bd297
commit 56c7b6b1cb
1 changed files with 2 additions and 0 deletions

View File

@ -266,6 +266,8 @@ public class DBHelper {
attributes.setValidFromUTC(now.getTime()); attributes.setValidFromUTC(now.getTime());
attributes.setHeightCM(prefsUser.getHeightCm()); attributes.setHeightCM(prefsUser.getHeightCm());
attributes.setWeightKG(prefsUser.getWeightKg()); attributes.setWeightKG(prefsUser.getWeightKg());
attributes.setSleepGoalHPD(prefsUser.getSleepDuration());
attributes.setStepsGoalSPD(prefsUser.getStepsGoal());
attributes.setUserId(user.getId()); attributes.setUserId(user.getId());
session.getUserAttributesDao().insert(attributes); session.getUserAttributesDao().insert(attributes);