aboutsummaryrefslogtreecommitdiff
path: root/src/volume-control.vala
diff options
context:
space:
mode:
Diffstat (limited to 'src/volume-control.vala')
-rw-r--r--src/volume-control.vala3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/volume-control.vala b/src/volume-control.vala
index 29c49f6..ba87de5 100644
--- a/src/volume-control.vala
+++ b/src/volume-control.vala
@@ -552,8 +552,7 @@ public class VolumeControl : Object
bool set_volume_internal (double volume)
{
- if (context.get_state () != Context.State.READY)
- return false;
+ return_val_if_fail (context.get_state () == Context.State.READY, false);
if (_volume != volume) {
_volume = volume;