diff --git a/src/abstract_client.cpp b/src/abstract_client.cpp index 21d0a3523d..d377a0ca1f 100644 --- a/src/abstract_client.cpp +++ b/src/abstract_client.cpp @@ -539,9 +539,9 @@ void AbstractClient::leaveDesktop(VirtualDesktop *virtualDesktop) void AbstractClient::setOnAllDesktops(bool b) { - if ((b && isOnAllDesktops()) || - (!b && !isOnAllDesktops())) + if (b == isOnAllDesktops()) { return; + } if (b) { setDesktops({}); } else {