From e0551fddb5899f97b2deed88d5a9e684ded97c9d Mon Sep 17 00:00:00 2001
From: Arnd Brugman <arndbrugman@gmail.com>
Date: Sun, 4 Oct 2015 08:48:13 +0200
Subject: [PATCH] FIX huepi.prototype.LightSetName

FIX huepi.prototype.LightSetName
---
 huepi.js | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/huepi.js b/huepi.js
index 3ba2b4a..5e34ce1 100755
--- a/huepi.js
+++ b/huepi.js
@@ -795,7 +795,7 @@ huepi.prototype.LightSetName = function(LightNr, Name)
     type: 'PUT',
     dataType: 'json',
     contentType: 'application/json',
-    url: 'http://' + this.BridgeIP + '/api/' + this.Username + '/light/' + this.LightGetId(LightNr),
+    url: 'http://' + this.BridgeIP + '/api/' + this.Username + '/lights/' + this.LightGetId(LightNr),
     data: '{"name" : "' + Name + '"}'
   });
 };
@@ -1576,8 +1576,10 @@ huepi.prototype.RulesGetData = function()
 //   this way its transparent and works for both Ids & Indices
 // reordered parameters to HelperXYtoRGBforModel = function(x, y, Brightness, Model)
 //
-//
 // using updated Philips hue Wide RGB D65, http://www.developers.meethue.com/documentation/color-conversions-rgb-xy
 //
+// 
+// FIX huepi.prototype.LightSetName 
+//
 //