mirror of
https://github.com/swift-project/pilotclient.git
synced 2026-04-04 08:36:52 +08:00
refs #937 Resolved clazy warnings: unnecessary detaching of containers.
This commit is contained in:
@@ -163,6 +163,6 @@ const QDBusArgument &operator >>(const QDBusArgument &arg, BlackCore::Context::C
|
||||
{
|
||||
QList<CLogSubscriptionPair> listOfPairs;
|
||||
arg >> listOfPairs;
|
||||
for (const auto &pair : listOfPairs) { hash.insert(pair.first, pair.second); }
|
||||
for (const auto &pair : as_const(listOfPairs)) { hash.insert(pair.first, pair.second); }
|
||||
return arg;
|
||||
}
|
||||
|
||||
@@ -552,7 +552,7 @@ namespace BlackCore
|
||||
QSharedPointer<IVoiceChannel> CContextAudio::getVoiceChannelBy(const CVoiceRoom &voiceRoom)
|
||||
{
|
||||
QSharedPointer<IVoiceChannel> voiceChannel;
|
||||
for (const auto &channel : m_voiceChannelMapping.values())
|
||||
for (const auto &channel : as_const(m_voiceChannelMapping))
|
||||
{
|
||||
if (channel->getVoiceRoom().getVoiceRoomUrl() == voiceRoom.getVoiceRoomUrl()) voiceChannel = channel;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user