1
0
mirror of https://github.com/unrealircd/unrealircd.git synced 2026-07-08 14:03:12 +02:00

Allow @if with loadmodule, just not module-loaded(). We need this.

This commit is contained in:
Bram Matthys
2026-03-22 17:07:46 +01:00
parent d467005816
commit 9b83fc0db9
+2 -3
View File
@@ -2047,10 +2047,9 @@ int config_loadmodules(void)
{
if (!strcmp(ce->name, "loadmodule"))
{
if (ce->conditional_config)
if (ce->conditional_config && ce->conditional_config->condition == IF_MODULE)
{
config_error("%s:%d: Currently you cannot have a 'loadmodule' statement "
"within an @if block, sorry.",
config_error("%s:%d: You cannot use @if module-loaded() around a 'loadmodule' statement.",
ce->file->filename, ce->line_number);
return 0;
}