We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 3e2b46f commit d809a2bCopy full SHA for d809a2b
src/siri.ts
@@ -162,6 +162,8 @@ interface commandDetection {
162
function: (bl: Bluelink) => Promise<string>
163
}
164
165
+// Note order matters in this list, as we check a sentence for presence of words
166
+// and certain words contain sub-words. Hence "unlock" needs to be before "lock" etc
167
const commandMap: commandDetection[] = [
168
{
169
words: ['status', 'remote'],
@@ -183,14 +185,14 @@ const commandMap: commandDetection[] = [
183
185
words: ['climate', 'off'],
184
186
function: climateOff,
187
},
- {
- words: ['lock'],
188
- function: lock,
189
- },
190
191
words: ['unlock'],
192
function: unlock,
193
+ {
+ words: ['lock'],
194
+ function: lock,
195
+ },
196
197
words: ['start', 'charging'],
198
function: startCharge,
0 commit comments