diff --git a/src/admin/src/Model/CategoryModel.php b/src/admin/src/Model/CategoryModel.php index ced1b4df41e..d62e0751f3a 100644 --- a/src/admin/src/Model/CategoryModel.php +++ b/src/admin/src/Model/CategoryModel.php @@ -61,8 +61,8 @@ public function getAdminCategory() $query = $db->getQuery(true) ->select('a.id, a.name') ->from("{$db->quoteName('#__kunena_categories')} AS a") - ->where("parentid={$db->quote('0')}") - ->where("id!={$db->quote($category->id)}") + ->where($db->quoteName('parentid') . '=' . $db->quote('0')) + ->where($db->quoteName('id') . '!=' . $db->quote($category->id)) ->order('ordering'); $db->setQuery($query);