Fixed some code scanning alerts
This commit is contained in:
@@ -17,6 +17,8 @@
|
||||
* along with LMS. If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
|
||||
#pragma once
|
||||
|
||||
#include "services/scrobbling/Exception.hpp"
|
||||
|
||||
namespace Scrobbling::ListenBrainz
|
||||
|
||||
@@ -23,7 +23,6 @@
|
||||
#include <Wt/Json/Object.h>
|
||||
#include <Wt/Json/Value.h>
|
||||
#include <Wt/Json/Parser.h>
|
||||
//#include <Wt/Json/Serializer.h>
|
||||
|
||||
#include "services/scrobbling/Exception.hpp"
|
||||
#include "Exception.hpp"
|
||||
|
||||
@@ -17,6 +17,8 @@
|
||||
* along with LMS. If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
|
||||
#pragma once
|
||||
|
||||
#include <string_view>
|
||||
|
||||
#include "FeedbackTypes.hpp"
|
||||
|
||||
@@ -234,7 +234,7 @@ namespace Scrobbling::ListenBrainz
|
||||
auto itContext {_userContexts.find(userId)};
|
||||
if (itContext == std::cend(_userContexts))
|
||||
{
|
||||
auto [itNewContext, inserted] {_userContexts.emplace(userId, userId)};
|
||||
[[maybe_unused]] auto [itNewContext, inserted] {_userContexts.emplace(userId, userId)};
|
||||
itContext = itNewContext;
|
||||
}
|
||||
|
||||
@@ -246,7 +246,7 @@ namespace Scrobbling::ListenBrainz
|
||||
{
|
||||
return std::any_of(std::cbegin(_userContexts), std::cend(_userContexts), [](const auto& contextEntry)
|
||||
{
|
||||
const auto& [userId, context] {contextEntry};
|
||||
[[maybe_unused]] const auto& [userId, context] {contextEntry};
|
||||
return context.syncing;
|
||||
});
|
||||
}
|
||||
|
||||
@@ -354,7 +354,7 @@ namespace Scrobbling::ListenBrainz
|
||||
auto itContext {_userContexts.find(userId)};
|
||||
if (itContext == std::cend(_userContexts))
|
||||
{
|
||||
auto [itNewContext, inserted] {_userContexts.emplace(userId, userId)};
|
||||
[[maybe_unused]] auto [itNewContext, inserted] {_userContexts.emplace(userId, userId)};
|
||||
itContext = itNewContext;
|
||||
}
|
||||
|
||||
@@ -366,7 +366,7 @@ namespace Scrobbling::ListenBrainz
|
||||
{
|
||||
return std::any_of(std::cbegin(_userContexts), std::cend(_userContexts), [](const auto& contextEntry)
|
||||
{
|
||||
const auto& [userId, context] {contextEntry};
|
||||
[[maybe_unused]] const auto& [userId, context] {contextEntry};
|
||||
return context.syncing;
|
||||
});
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user