1
0
mirror of https://github.com/anope/anope.git synced 2026-06-25 10:36:38 +02:00

Made the help command description code more sane

This commit is contained in:
Adam
2011-02-11 03:12:39 -05:00
parent 7bdf592f7e
commit 2529ff6dae
148 changed files with 215 additions and 939 deletions
+2 -14
View File
@@ -95,14 +95,7 @@ const char *anope_gettext(const char *string)
setlocale(LC_ALL, "");
#endif
Anope::string translated = translated_string ? translated_string : "";
if (Config->UseStrictPrivMsg)
translated = translated.replace_all_cs("%R", "/");
else
translated = translated.replace_all_cs("%R", "/msg ");
return translated.c_str();
return translated_string != NULL ? translated_string : "";
}
#else
void PushLanguage(const Anope::string &, Anope::string)
@@ -115,12 +108,7 @@ void PopLanguage()
const char *anope_gettext(const char *string)
{
Anope::string translated = string ? string : "";
if (Config->UseStrictPrivMsg)
translated = translated.replace_all_cs("%R", "/");
else
translated = translated.replace_all_cs("%R", "/msg ");
return translated.c_str();
return string != NULL ? string : "";
}
#endif