Skip to content

Commit 12bed2b

Browse files
committed
fixed: fatal exception on question detail page
fixes #33
1 parent 9015a74 commit 12bed2b

File tree

1 file changed

+2
-2
lines changed
  • views/default/resources/questions

1 file changed

+2
-2
lines changed

views/default/resources/questions/view.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -63,11 +63,11 @@ function (QueryBuilder $qb, $main_alias) {
6363
->where($qb->compare('entity_guid', '=', "{$main_alias}.guid"))
6464
->andWhere($qb->compare('name', '=', 'likes', ELGG_VALUE_STRING));
6565

66-
return "({$sub->getSQL()}) as likes_count";
66+
return "({$sub->getSQL()}) as number_of_likes";
6767
},
6868
];
6969
$options['order_by'] = [
70-
new OrderByClause('likes_count', 'DESC'),
70+
new OrderByClause('number_of_likes', 'DESC'),
7171
new OrderByClause('e.time_created', 'ASC'),
7272
];
7373
}

0 commit comments

Comments
 (0)