Skip to content

Commit d37b6be

Browse files
committed
Updated callbacks documentation to match 2.7.4
1 parent 758ab36 commit d37b6be

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

doc-examples/callbacks.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -143,9 +143,9 @@ bool onSetVolume(const String &deviceId, int &volume) {
143143
//! [onAdjustVolume]
144144
int absoluteVolume;
145145

146-
bool onAdjustVolume(const String &deviceId, int &volumeDelta) {
146+
bool onAdjustVolume(const String &deviceId, int &volumeDelta, bool volumeDefault) {
147147
absoluteVolume += volumeDelta; // calculate absolute volume
148-
Serial.printf("Device %s volume changed about %i to %d\r\n", deviceId.c_str(), volumeDelta, absoluteVolume);
148+
Serial.printf("Device %s volume changed about %i to %d (default: %s)\r\n", deviceId.c_str(), volumeDelta, absoluteVolume, volumeDefault);
149149
volumeDelta = absoluteVolume; // return absolute volume
150150
return true; // request handled properly
151151
}

0 commit comments

Comments
 (0)