if (isset($category[$x['parent_id']])) {
$category[$x['parent_id']]['subcat'][$x['category_id']] = $x;
} else {
- $templateData['genError'] = 'There is at least one sub-category that does not have a matching top-level parent! ('.$x['name'].')<br>
- This could be a third-level category. Perhaps we can handle this when we have time to work on this a bit.';
- $failure = true;
+ // Since the parent doesn't exist, we're just going to make this one a parent.
+ $category[$x['category_id']] = $x;
+ $category[$x['category_id']]['subcat'] = array();
}
}
}