mirror of
https://github.com/Expand-sys/CCash
synced 2026-03-22 20:47:10 +11:00
🔥 removed recieving
This commit is contained in:
parent
fb3000820f
commit
3b36ec90cc
2 changed files with 2 additions and 4 deletions
|
|
@ -180,7 +180,6 @@ public:
|
|||
|
||||
Json::Value GetLogs(const std::string &name, const std::string &attempt)
|
||||
{
|
||||
Json::Value res;
|
||||
bool state = false;
|
||||
users.if_contains(name, [&state, &attempt](const User &u) {
|
||||
state = XXH3_64bits(attempt.data(), attempt.size()) == u.password;
|
||||
|
|
@ -188,6 +187,7 @@ public:
|
|||
|
||||
if (state)
|
||||
{
|
||||
Json::Value res;
|
||||
logs.if_contains(name, [&res](const Log &l) {
|
||||
for (uint32_t i = l.data.size() - 1; i >= 0; --i)
|
||||
{
|
||||
|
|
@ -198,7 +198,6 @@ public:
|
|||
res[99 - i]["to"] = l.data[i].to;
|
||||
res[99 - i]["from"] = l.data[i].from;
|
||||
res[99 - i]["amount"] = l.data[i].amount;
|
||||
res[99 - i]["recieving"] = l.data[i].recieving;
|
||||
}
|
||||
});
|
||||
return res;
|
||||
|
|
|
|||
|
|
@ -5,7 +5,6 @@ struct Transaction
|
|||
{
|
||||
std::string from = "", to = "";
|
||||
uint32_t amount = 0;
|
||||
bool recieving = false;
|
||||
|
||||
void Concatinate(std::string &s)
|
||||
{
|
||||
|
|
@ -19,7 +18,7 @@ struct Transaction
|
|||
}
|
||||
|
||||
Transaction() = default;
|
||||
Transaction(std::string from_str, std::string to_str, uint32_t amount, bool recieving) : amount(amount), recieving(recieving)
|
||||
Transaction(std::string from_str, std::string to_str, uint32_t amount) : amount(amount)
|
||||
{
|
||||
Concatinate(from_str);
|
||||
Concatinate(to_str);
|
||||
|
|
|
|||
Loading…
Reference in a new issue