From 7d00406ae7b1f7030673b7cc4672d631a4998135 Mon Sep 17 00:00:00 2001
From: Erick Hitter <services@ethitter.com>
Date: Sat, 10 Sep 2016 15:50:04 -0700
Subject: [PATCH] Formatting and docs cleanup

---
 index.js | 9 ++++++---
 1 file changed, 6 insertions(+), 3 deletions(-)

diff --git a/index.js b/index.js
index 3bce2a2..c0e3d73 100644
--- a/index.js
+++ b/index.js
@@ -34,8 +34,8 @@ function buttonActivated( mac ) {
     var req = {
         url: homeAssistantUrl + 'states/' + config.home_assistant_alarm_entity_id,
         headers: {
-            "Content-Type": "application/json",
-            "x-ha-access": config.home_assistant_pass
+            'Content-Type': 'application/json',
+            'x-ha-access': config.home_assistant_pass
         }
     };
 
@@ -69,8 +69,11 @@ function buttonActivated( mac ) {
 
         // Build new request to update state
         req.method = 'POST';
-        req.body   = JSON.stringify( { "entity_id": config.home_assistant_alarm_entity_id } );
+        req.body   = JSON.stringify( {
+            'entity_id': config.home_assistant_alarm_entity_id
+        } );
 
+        // Make request to change alarm status
         request( req, function( err, res, body ) {
             // Handle error states
             if ( err ) {
-- 
GitLab