simplificator / simplificator-withings

a ruby implementation for the withing WIFI connected bodyscale
MIT License
48 stars 26 forks source link

Unused code in measurement_group.rb #11

Closed galiat closed 9 years ago

galiat commented 10 years ago

In measurement_group.rb, are the first 4 lines of the class used?

ATTRIBUTION_DEVICE = 0 ATTRIBUTION_DEVICE_AMBIGUOUS = 1 ATTRIBUTION_DEVICE_MANUALLY = 2 ATTRIBUTION_DEVICE_MANUALLY_DURING_CREATION = 4

pascalbetz commented 10 years ago

Thanks for the Feedback. We planned some work on the Gem next week and will look into it. If you have a PullRequest that would be great to.

@pic can you look into this as well?

pic commented 10 years ago

@galiat @pascalbetz they are not used indeed but I suppose they could be used to validate the value of

@attribution = params['attrib']

at line 27 below. Pascal?

pascalbetz commented 10 years ago

@galiat @pic

These values can be used in a client of the library to compare the attribution value. I think it's nice if they are there and defined in the library.

@galiat what do you think?