diff options
author | Thorbjørn Lindeijer <bjorn@lindeijer.nl> | 2023-05-16 12:39:54 +0200 |
---|---|---|
committer | Thorbjørn Lindeijer <bjorn@lindeijer.nl> | 2023-05-16 17:00:12 +0200 |
commit | 3e4f21ba9842d767044155c926ee85bebe944361 (patch) | |
tree | ed82e7207a87181a38d37e530c14615b1a1a0f13 /src | |
parent | 157187d91bdb98e5e9daf4479753ffce02961d5f (diff) | |
download | manaserv-3e4f21ba9842d767044155c926ee85bebe944361.tar.gz manaserv-3e4f21ba9842d767044155c926ee85bebe944361.tar.bz2 manaserv-3e4f21ba9842d767044155c926ee85bebe944361.tar.xz manaserv-3e4f21ba9842d767044155c926ee85bebe944361.zip |
Added some info messages related to Stellar login
Something doesn't seem to be working right...
Diffstat (limited to 'src')
-rw-r--r-- | src/account-server/accounthandler.cpp | 4 | ||||
-rw-r--r-- | src/account-server/storage.cpp | 2 | ||||
-rw-r--r-- | src/dal/recordset.cpp | 2 |
3 files changed, 6 insertions, 2 deletions
diff --git a/src/account-server/accounthandler.cpp b/src/account-server/accounthandler.cpp index 6c1e10c8..4a4c73cf 100644 --- a/src/account-server/accounthandler.cpp +++ b/src/account-server/accounthandler.cpp @@ -1093,6 +1093,8 @@ void AccountHandler::handleStellarLogin(const std::string &token, const std::str auto acc = storage->getAccount(pubKey); if (acc) { + LOG_INFO("Stellar login: Found existing account for public key " << pubKey << ", ID " << acc->getID()); + // Set lastLogin date of the account. time_t login; time(&login); @@ -1110,6 +1112,8 @@ void AccountHandler::handleStellarLogin(const std::string &token, const std::str { // On-demand account creation for public keys acc = createAccount(pubKey, std::string(), std::string()); + + LOG_INFO("Stellar login: Created account for public key " << pubKey << ", ID " << acc->getID()); } MessageOut reply(APMSG_LOGIN_RESPONSE); diff --git a/src/account-server/storage.cpp b/src/account-server/storage.cpp index 9ff25f69..a1270dca 100644 --- a/src/account-server/storage.cpp +++ b/src/account-server/storage.cpp @@ -890,7 +890,7 @@ bool Storage::updateCharacter(const CharacterData &character) void Storage::addAccount(Account &account) { - assert(account.getCharacters().size() == 0); + assert(account.getCharacters().empty()); using namespace dal; diff --git a/src/dal/recordset.cpp b/src/dal/recordset.cpp index 69104933..1c9d2879 100644 --- a/src/dal/recordset.cpp +++ b/src/dal/recordset.cpp @@ -53,7 +53,7 @@ void RecordSet::clear() */ bool RecordSet::isEmpty() const { - return mRows.size() == 0; + return mRows.empty(); } /** |