Fix thing with inspect on non-python function for libnotify
This commit is contained in:
parent
9a069bdc10
commit
e16965e771
1 changed files with 5 additions and 1 deletions
6
toast.py
6
toast.py
|
@ -74,7 +74,11 @@ class ToastMachine(object):
|
||||||
t = None
|
t = None
|
||||||
for (k,v) in self.machine.types.iteritems():
|
for (k,v) in self.machine.types.iteritems():
|
||||||
if self.machine.type == k:
|
if self.machine.type == k:
|
||||||
args = inspect.getargspec(v.__init__).args
|
try:
|
||||||
|
args = inspect.getargspec(v.__init__).args
|
||||||
|
except:
|
||||||
|
args = []
|
||||||
|
|
||||||
extras = {}
|
extras = {}
|
||||||
if 'parent' in args:
|
if 'parent' in args:
|
||||||
extras['parent'] = self.machine.parent
|
extras['parent'] = self.machine.parent
|
||||||
|
|
Loading…
Reference in a new issue