Permalink
Browse files

Fix modp{erl,ython}, these modules should set a "default" module type…

… for its submodules

These modules were broken by d48ae67
  • Loading branch information...
1 parent 9006fec commit e70b6854a3569226520294774b2c133f8593f602 Kyle Fuller committed Aug 30, 2011
Showing with 3 additions and 0 deletions.
  1. +1 −0 modules/modperl.cpp
  2. +2 −0 modules/modpython/znc.py
View
@@ -148,6 +148,7 @@ class CModPerl: public CModule {
case Perl_Loaded:
result = HALT;
if (4 == ret) {
+ ModInfo.SetDefaultType(CModInfo::UserModule);
ModInfo.AddType(CModInfo::UserModule);
ModInfo.SetDescription(PString(ST(2)));
ModInfo.SetName(sModule);
View
@@ -529,6 +529,7 @@ def get_mod_info(modname, retmsg, modinfo):
pymodule.__file__, modname)
return 1
cl = pymodule.__dict__[modname]
+ modinfo.SetDefaultType(cl.module_types[0])
for module_type in cl.module_types:
modinfo.AddType(module_type)
modinfo.SetDescription(cl.description)
@@ -562,6 +563,7 @@ def get_mod_info_path(path, modname, modinfo):
modinfo.SetWikiPage(cl.wiki_page)
modinfo.SetName(modname)
modinfo.SetPath(pymodule.__file__)
+ modinfo.SetDefaultType(cl.module_types[0])
for module_type in cl.module_types:
modinfo.AddType(module_type)

0 comments on commit e70b685

Please sign in to comment.