We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 4831b70 commit 012d144Copy full SHA for 012d144
libyang/context.py
@@ -133,12 +133,11 @@ def get_module_data(
133
Tuple of format string and YANG (sub)module schema
134
"""
135
if self._module_data_clb is None:
136
- return "", None
137
- fmt_str, module_data = self._module_data_clb(
138
- mod_name, mod_rev, submod_name, submod_rev
139
- )
140
- if module_data is None:
141
- return fmt_str, None
+ return None
+ ret = self._module_data_clb(mod_name, mod_rev, submod_name, submod_rev)
+ if ret is None:
+ fmt_str, module_data = ret
142
module_data_c = str2c(module_data)
143
self._cdata_modules.append(module_data_c)
144
return fmt_str, module_data_c
0 commit comments