diff options
Diffstat (limited to 'modules')
| -rw-r--r-- | modules/xml.pl | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/modules/xml.pl b/modules/xml.pl index a3c6e85..9224649 100644 --- a/modules/xml.pl +++ b/modules/xml.pl @@ -16,7 +16,8 @@ sub readXML { $::channels = $::xs1->XMLin( "$p/channels.xml", ForceArray => \@fchan ); $::users = $::xs1->XMLin( "$p/users.xml", ForceArray => 'person'); $::commands = $::xs1->XMLin( "$p/commands.xml", ForceArray => [qw/command/]); - $::mysql = $::xs1->XMLin( "$p/mysql.xml", ForceArray => []); + $::mysql = $::xs1->XMLin( "$p/mysql.xml", ForceArray => ['ident', 'geco'], + 'GroupTags' => { ignoredidents => 'ident', ignoredgecos => 'geco' }); $::dnsbl = $::xs1->XMLin( "$p/dnsbl.xml", ForceArray => []); $::rules = $::xs1->XMLin( "$p/rules.xml", ForceArray => []); $::restrictions = $::xs1->XMLin( "$p/restrictions.xml", ForceArray => ['host', 'nick', 'account']); @@ -29,9 +30,15 @@ sub writeXML { writeUsers(); writeRestrictions(); writeBlacklist(); + writeMysql(); # $::xs1->XMLout($::commands, RootName => 'commands', KeyAttr => ['id']) > io("$::cset/commands.xml"); } +sub writeMysql { + $::settingschanged=1; + $::xs1->XMLout($::mysql, RootName => 'mysql', KeyAttr => ['id']) > io("$::cset/mysql.xml"); +} + sub writeChannels { $::settingschanged=1; $::xs1->XMLout($::channels, RootName => 'channels', KeyAttr => ['id'], NumericEscape => 2) > io("$::cset/channels.xml"); |
