fixed database lock on ModifyBalance and SetBalance