Skip to content

Commit

Permalink
rename variable everywhere it is used
Browse files Browse the repository at this point in the history
  • Loading branch information
chee committed Aug 5, 2017
1 parent 6446543 commit 3e04d53
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions index.js
Expand Up @@ -185,8 +185,8 @@ function pair (light, callback) {
.concat(data.slice(0, 8))
.concat([...encryptedKey].slice(0, 8))

pairChar.write(new Buffer(packet), true, () => {
pairChar.read((error, received) => {
pairCharacteristic.write(new Buffer(packet), true, () => {
pairCharacteristic.read((error, received) => {
const sk = generateSk(
name,
password,
Expand All @@ -201,7 +201,7 @@ function pair (light, callback) {
packetCount = packetCount > 0xffff ? 1 : packetCount + 1
return new Promise(resolve => {
const resolver = createResolver({callback, resolve})
commandChar.write(encryptedPacket, false, resolver)
commandCharacteristic.write(encryptedPacket, false, resolver)
})
}
return resolver(dispatch)
Expand Down

0 comments on commit 3e04d53

Please sign in to comment.