* fix bug: get stories of custom child module error.

This commit is contained in:
xia0ta0
2014-10-30 14:50:06 +08:00
parent 4fedcd4234
commit f5b311cd0f
+1 -1
View File
@@ -875,7 +875,7 @@ class treeModel extends model
$module = $this->dao->select('id,type,parent')->from(TABLE_MODULE)->where('id')->eq((int)$moduleID)->fetch();
if(empty($module)) return 0;
if($module->id and $module->type != 'story')
while(!empty($module) and $module->id and $module->type != 'story')
{
$module = $this->dao->select('id,type,parent')->from(TABLE_MODULE)->where('id')->eq($module->parent)->fetch();
}