Skip to content

Commit

Permalink
Remove reliance on static acquaintances_initialized variable
Browse files Browse the repository at this point in the history
It wasn't set to true anywhere before anyway
  • Loading branch information
Vultraz committed Jan 30, 2016
1 parent 625c6bc commit 82ea765
Showing 1 changed file with 1 addition and 4 deletions.
5 changes: 1 addition & 4 deletions src/game_preferences.cpp
Expand Up @@ -64,8 +64,6 @@ std::map<std::string, std::vector<std::string> > history_map;

std::map<std::string, preferences::acquaintance> acquaintances;

bool acquaintances_initialized = false;

std::vector<std::string> mp_modifications;
bool mp_modifications_initialized = false;
std::vector<std::string> sp_modifications;
Expand Down Expand Up @@ -241,8 +239,7 @@ admin_authentication_reset::~admin_authentication_reset()
}

static void load_acquaintances() {
if(!acquaintances_initialized) {
acquaintances.clear();
if(acquaintances.empty()) {
BOOST_FOREACH(const config &acfg, preferences::get_prefs()->child_range("acquaintance")) {
acquaintance ac = acquaintance(acfg);
acquaintances[ac.get_nick()] = ac;
Expand Down

0 comments on commit 82ea765

Please sign in to comment.