mirror of
https://github.com/Expand-sys/CCash
synced 2025-12-18 17:12:14 +11:00
🐛 fixed hash loading bug
This commit is contained in:
parent
e4b6d2987d
commit
bd8bf25b08
2 changed files with 3 additions and 3 deletions
|
|
@ -199,7 +199,7 @@ public:
|
||||||
user_save.close();
|
user_save.close();
|
||||||
for (const auto &u : temp.getMemberNames())
|
for (const auto &u : temp.getMemberNames())
|
||||||
{
|
{
|
||||||
users.try_emplace(u, temp[u]["balance"].asUInt(), std::move(temp[u]["password"].asString()));
|
users.try_emplace(u, temp[u]["balance"].asUInt(), std::move(temp[u]["password"].asUInt64()));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -5,7 +5,7 @@
|
||||||
struct User
|
struct User
|
||||||
{
|
{
|
||||||
uint_fast32_t balance = 0;
|
uint_fast32_t balance = 0;
|
||||||
uint_fast64_t password;
|
uint64_t password;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @brief User constructor
|
* @brief User constructor
|
||||||
|
|
@ -26,7 +26,7 @@ struct User
|
||||||
{
|
{
|
||||||
Json::Value res;
|
Json::Value res;
|
||||||
res["balance"] = (Json::UInt)balance;
|
res["balance"] = (Json::UInt)balance;
|
||||||
res["password"] = (Json::LargestUInt)password;
|
res["password"] = (Json::UInt64)password;
|
||||||
return res;
|
return res;
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
Loading…
Reference in a new issue