Use const'ref here

This commit is contained in:
Laurent Montel 2022-01-04 14:00:41 +01:00
parent 5f83f2a781
commit 9521ca1e56

View file

@ -1821,7 +1821,7 @@ bool Workspace::shortcutAvailable(const QKeySequence &cut, AbstractClient* ignor
// Check if the shortcut is already registered
const QList<KGlobalShortcutInfo> registeredShortcuts = KGlobalAccel::getGlobalShortcutsByKey(cut);
for (const auto shortcut : registeredShortcuts) {
for (const auto &shortcut : registeredShortcuts) {
// Only return "not available" if is not a client activation shortcut, as it may be no longer valid
if (!shortcut.uniqueName().startsWith(QStringLiteral("_k_session:"))) {
return false;