TinkerWorks / HomeSensorHub

GNU General Public License v3.0
3 stars 2 forks source link

Refactor the Sensor class. #13

Closed BabyCakes13 closed 4 years ago

BabyCakes13 commented 4 years ago

Thank you ;). Fixed in b43766aedcc6e5e359ce4d374a32b670fe10cd58. After this I wonder if the Sensor class is still necessary... After removing the function which build the payload from this class, now it only has the get_name() functionality (which is used) and that's it (and that is only used when building the Payload object. The name could be easily send to the Payload class at collection level; without having to create a Sensor object only to store that. The code is smelly :).

_Originally posted by @BabyCakes13 in https://github.com/_render_node/MDI0OlB1bGxSZXF1ZXN0UmV2aWV3Q29tbWVudDQ2NTk4NDQ1MQ==/comments/review_comment_