alexa_hue 1.1.5 → 1.1.6
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/alexa_hue/version.rb +1 -1
- data/lib/alexa_hue.rb +20 -20
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 6c1f387288b46ef7cba0558ce83099a6bd566837
|
4
|
+
data.tar.gz: 5bb84e547158830f9f4735d06c89c450812ae3cd
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 8d65bd8507f8ee0037ea48e888de2b2a6bfc76316c7661b0e15c4b9391f4d0941fbf0f3f6a87d84141b4066199e73b5726146e3aa7aaec9252ee4b8909fb000c
|
7
|
+
data.tar.gz: 016a1a88aa3fd3fe0d52563f4ebee4ddb1c51a193a37690821d0475c45d6f7f53c1434586c3faf2b3f14cb485e1cb1281336c794d8a7a9b69d615eb3996bdf87
|
data/lib/alexa_hue/version.rb
CHANGED
data/lib/alexa_hue.rb
CHANGED
@@ -61,27 +61,27 @@ module Hue
|
|
61
61
|
|
62
62
|
|
63
63
|
|
64
|
-
if @echo_request.slots.lights.nil? && @echo_request.slots.scene.nil? && @echo_request.slots.savescene.nil?
|
65
|
-
|
66
|
-
end
|
64
|
+
# if @echo_request.slots.lights.nil? && @echo_request.slots.scene.nil? && @echo_request.slots.savescene.nil?
|
65
|
+
# halt AlexaObjects::Response.new(end_session: false, spoken_response: "Please specify which light or lights you'd like to adjust. I'm ready to control the lights.").to_json
|
66
|
+
# end
|
67
67
|
|
68
|
-
if @echo_request.slots.lights
|
69
|
-
|
70
|
-
|
71
|
-
|
72
|
-
end
|
68
|
+
# if @echo_request.slots.lights
|
69
|
+
# if @echo_request.slots.lights.scan(/light|lights/).empty?
|
70
|
+
# halt AlexaObjects::Response.new(end_session: false, spoken_response: "Please specify which light or lights you'd like to adjust. I'm ready to control the lights.").to_json
|
71
|
+
# end
|
72
|
+
# end
|
73
73
|
|
74
|
-
if @echo_request.slots.lights
|
75
|
-
|
76
|
-
|
77
|
-
|
78
|
-
|
79
|
-
|
80
|
-
|
81
|
-
|
82
|
-
|
83
|
-
|
84
|
-
end
|
74
|
+
# if @echo_request.slots.lights
|
75
|
+
# if @echo_request.slots.lights.include?('lights')
|
76
|
+
# if !(switch.list_groups.keys.join(', ').downcase.include?("#{@echo_request.slots.lights.sub(' lights','')}"))
|
77
|
+
# halt AlexaObjects::Response.new(spoken_response: "I couldn't find a group with the name #{@echo_request.slots.lights}").to_json
|
78
|
+
# end
|
79
|
+
# elsif @echo_request.slots.lights.include?('light')
|
80
|
+
# if !(switch.list_lights.keys.join(', ').downcase.include?("#{@echo_request.slots.lights.sub(' light','')}"))
|
81
|
+
# halt AlexaObjects::Response.new(spoken_response: "I couldn't find a light with the name #{@echo_request.slots.lights}").to_json
|
82
|
+
# end
|
83
|
+
# end
|
84
|
+
# end
|
85
85
|
|
86
86
|
|
87
87
|
#if @string.include?('light ')
|
@@ -92,7 +92,7 @@ module Hue
|
|
92
92
|
# halt r.without_card.to_json
|
93
93
|
# end
|
94
94
|
#end
|
95
|
-
switch.voice @string
|
95
|
+
Thread.start { switch.voice @string }
|
96
96
|
|
97
97
|
return AlexaObjects::Response.new(spoken_response: "okay").to_json
|
98
98
|
end
|