Simplify some code.

Calling insert() on a range instead of explicitly looping. It just
makes the code a little simpler for a human to read.
This commit is contained in:
JaMiT 2013-06-22 16:59:23 -05:00
parent b42e7ff0f5
commit dbd4fdc9d9

View File

@ -148,9 +148,7 @@ void team::team_info::read(const config &cfg)
}
std::vector<std::string> recruits = utils::split(cfg["recruit"]);
for(std::vector<std::string>::const_iterator i = recruits.begin(); i != recruits.end(); ++i) {
can_recruit.insert(*i);
}
can_recruit.insert(recruits.begin(), recruits.end());
// at the start of a scenario "start_gold" is not set, we need to take the
// value from the gold setting (or fall back to the gold default)