From 9ae50f72d9727c9eeade38798815b13af6b99f86 Mon Sep 17 00:00:00 2001 From: Alex Dedul Date: Sat, 11 Aug 2007 00:20:21 +0000 Subject: [PATCH] Tweaks to plugins tray messages. --- src/plugins.py | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/src/plugins.py b/src/plugins.py index a6bbb8c8a..21b33d24d 100644 --- a/src/plugins.py +++ b/src/plugins.py @@ -97,8 +97,11 @@ class PluginManager: tray_message = "" for name in self.enabled_plugins.keys(): plugin = self.enabled_plugins[name] - if 'get_tray_message' in dir(plugin): - tray_message = tray_message + '\n' + plugin.get_tray_message() + if hasattr(plugin, 'get_tray_message'): + plugin_tray_message = plugin.get_tray_message() + if plugin_tray_message: + tray_message += '\n' + plugin_tray_message + return tray_message def update_active_plugins(self):