diff --git a/docs/advanced-relay-config.md b/docs/advanced-relay-config.md index 6d5ac27..be96742 100644 --- a/docs/advanced-relay-config.md +++ b/docs/advanced-relay-config.md @@ -14,9 +14,9 @@ a: ### Custom Clientbot Styles -Custom Clientbot styles can be applied for any of Clientbot's supported events, by defining keys in the format `relay::clientbot_styles::`. As of 2.0-beta1, you can also set this per-network by defining options in the form `servers::::relay_clientbot_styles::` (Note: defining Clientbot styles locally will override the global `clientbot_styles` block and cause all values under it to be ignored for that network). +Custom Clientbot styles can be applied for any of Clientbot's supported events, by defining keys in the format `relay::clientbot_styles::`. As of PyLink 2.1, you can also override options per network by defining them in the form `servers::::relay_clientbot_styles::` -See below for a list of supported events and their default values (as of 2.0-beta1). +See below for a list of supported events and their default values (as of PyLink 2.1). A common use case for this feature is to turn off or adjust colors/formatting; this is explicitly documented [below](#disabling-colorscontrol-codes). diff --git a/plugins/relay_clientbot.py b/plugins/relay_clientbot.py index 3d02b2b..25eb8a7 100644 --- a/plugins/relay_clientbot.py +++ b/plugins/relay_clientbot.py @@ -87,7 +87,7 @@ def cb_relay_core(irc, source, command, args): # Try to fetch the format for the given command from the relay:clientbot_styles:$command # key, falling back to one defined in default_styles above, and then nothing if not found # there. - text_template = irc.get_service_option('relay', 'clientbot_styles', {}).get( + text_template = irc.get_service_options('relay', 'clientbot_styles', dict).get( real_command, default_styles.get(real_command, '')) text_template = string.Template(text_template)