Skip to content

Commit

Permalink
fix this.name -> adapter.name
Browse files Browse the repository at this point in the history
  • Loading branch information
foxriver76 committed Sep 20, 2023
1 parent 3f543c6 commit 018a659
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions main.js
Original file line number Diff line number Diff line change
Expand Up @@ -1480,12 +1480,12 @@ async function takeSonosState(ip, sonosState) {
}
}
if (fileData) {
await adapter.writeFileAsync(this.name, fileName, fileData);
await adapter.writeFileAsync(adapter.name, fileName, fileData);
adapter.setState({
device: 'root',
channel: ip,
state: 'current_cover'
}, { val: `/files/${this.name}/${fileName}`, ack: true });
}, { val: `/files/${adapter.name}/${fileName}`, ack: true });
}
}

Expand Down Expand Up @@ -1561,8 +1561,8 @@ async function syncCoverFileToStorage(fileName, ip) {
}

if (fileData) {
await adapter.writeFileAsync(this.name, fileName, fileData);
adapter.setState({ device: 'root', channel: ip, state: 'current_cover' }, { val: `/files/${this.name}/${fileName}`, ack: true });
await adapter.writeFileAsync(adapter.name, fileName, fileData);
adapter.setState({ device: 'root', channel: ip, state: 'current_cover' }, { val: `/files/${adapter.name}/${fileName}`, ack: true });
}
}

Expand Down

0 comments on commit 018a659

Please sign in to comment.