Review fixes.

This commit is contained in:
vng 2015-07-09 18:06:54 +03:00 committed by Alex Zolotarev
parent 789444c7e9
commit 3877641793
2 changed files with 6 additions and 1 deletions

View file

@ -237,7 +237,11 @@ namespace ftype
if (!m_isKey)
{
// Take numbers only for "capital" and "admin_level".
// Take numbers only for "capital" and "admin_level" now.
// NOTE! If you add a new type into classificator, which has a number in it
// (like admin_level=1 or capital=2), please don't forget to insert it here too.
// Otherwise generated data will not contain your newly added features.
if (strings::is_number(v))
return (k == "admin_level" || k == "capital");
}

View file

@ -171,6 +171,7 @@ bool FeatureParams::AddName(string const & lang, string const & s)
if (IsDummyName(s))
return false;
// The "default" new name will replace the old one if any (e.g. from AddHouseName call).
name.AddString(lang, s);
return true;
}