diff --git a/src/text_snippets.cpp b/src/text_snippets.cpp index 6327b13021d53..6ed5e5a834f97 100644 --- a/src/text_snippets.cpp +++ b/src/text_snippets.cpp @@ -298,7 +298,7 @@ std::optional snippet_library::random_from_category( const std::str const uint64_t ids_weighted_sum = it->second.ids.empty() ? 0 : it->second.ids.back().weight_acc; const uint64_t weight_sum = ids_weighted_sum + - ( it->second.no_id.empty() ? 0 : it->second.no_id.back().weight_acc ); + ( it->second.no_id.empty() ? 0 : it->second.no_id.back().weight_acc ); if( weight_sum == 0 ) { return std::nullopt; }