From: Maxim Mamontov <faust.madf@gmail.com>
Date: Sun, 25 Jan 2015 18:22:19 +0000 (+0200)
Subject: Handle cash changes properly.
X-Git-Tag: 2.409~201
X-Git-Url: https://git.stg.codes/stg.git/commitdiff_plain/eb94b3b8e12fb7e862803f6eafdefa5833d9b037?ds=sidebyside

Handle cash changes properly.
---

diff --git a/projects/stargazer/plugins/configuration/sgconfig/parser_users.cpp b/projects/stargazer/plugins/configuration/sgconfig/parser_users.cpp
index cd66ec9e..7c6a46bb 100644
--- a/projects/stargazer/plugins/configuration/sgconfig/parser_users.cpp
+++ b/projects/stargazer/plugins/configuration/sgconfig/parser_users.cpp
@@ -584,9 +584,11 @@ int CHG_USER::ApplyChanges()
                                            &m_store,
                                            m_cashMsg))
                 return -1;
-            else
-                if (!u->GetProperty().cash.Set(m_usr.cash.const_data(), &m_currAdmin, m_login, &m_store, m_cashMsg))
-                    return -1;
+        }
+        else
+        {
+            if (!u->GetProperty().cash.Set(m_usr.cash.const_data(), &m_currAdmin, m_login, &m_store, m_cashMsg))
+                return -1;
         }