mirror of
https://github.com/kovidgoyal/calibre.git
synced 2025-07-09 03:04:10 -04:00
Fix template function source code unavailable when running not running from source
This commit is contained in:
commit
50e353cc65
@ -187,7 +187,7 @@ class ConfigWidget(ConfigWidgetBase, Ui_Form):
|
||||
self.argument_count.setValue(func.arg_count)
|
||||
self.documentation.setText(func.doc)
|
||||
if txt in self.builtins:
|
||||
if hasattr(func, 'program_text'):
|
||||
if hasattr(func, 'program_text') and func.program_text:
|
||||
self.program.setPlainText(func.program_text)
|
||||
elif txt in self.builtin_source_dict:
|
||||
self.program.setPlainText(self.builtin_source_dict[txt])
|
||||
|
Loading…
x
Reference in New Issue
Block a user