Cleaning up code as per @s0undt3ch
Merge pull request #12068 from techhat/sensors

Cleaning up code as per @s0undt3ch