From abbc24e9c1e987229f591a722bc8e356e00ff755 Mon Sep 17 00:00:00 2001 From: Charles Haley <> Date: Wed, 25 Jul 2012 08:58:08 +0200 Subject: [PATCH] Properly handle the default argument in get_option when the requested plugin does not exist. --- src/calibre/gui2/device.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/calibre/gui2/device.py b/src/calibre/gui2/device.py index 8364e06f0f..f08f87bf80 100644 --- a/src/calibre/gui2/device.py +++ b/src/calibre/gui2/device.py @@ -539,7 +539,7 @@ class DeviceManager(Thread): # {{{ return self.dynamic_plugin_responses.get() except: traceback.print_exc() - return None + return kwargs.get('default', None) # The dynamic plugin methods below must be called on the GUI thread. They # will switch to the device thread before calling the plugin.