Core/Analytics: Make MakeUniqueId() a const member function

This function doesn't modify instance state, so we can mark it as const.
This commit is contained in:
Lioncash 2019-06-03 19:37:33 -04:00
parent a5caa95a4b
commit 57454e90a7
2 changed files with 2 additions and 2 deletions

View File

@ -101,7 +101,7 @@ void DolphinAnalytics::GenerateNewIdentity()
SConfig::GetInstance().SaveSettings();
}
std::string DolphinAnalytics::MakeUniqueId(std::string_view data)
std::string DolphinAnalytics::MakeUniqueId(std::string_view data) const
{
std::array<u8, 20> digest;
const auto input = std::string{m_unique_id}.append(data);

View File

@ -89,7 +89,7 @@ private:
// Returns a unique ID derived on the global unique ID, hashed with some
// report-specific data. This avoid correlation between different types of
// events.
std::string MakeUniqueId(std::string_view data);
std::string MakeUniqueId(std::string_view data) const;
// Unique ID. This should never leave the application. Only used derived
// values created by MakeUniqueId.