"parent = id" is replaced with gravity check

This commit is contained in:
Michael 2020-05-28 16:02:36 +00:00
commit 0acb5d4558
6 changed files with 12 additions and 9 deletions

View file

@ -1287,7 +1287,7 @@ function photos_content(App $a)
}
if (!empty($link_item['parent']) && !empty($link_item['uid'])) {
$condition = ["`parent` = ? AND `parent` != `id`", $link_item['parent']];
$condition = ["`parent` = ? AND `gravity` != ?", $link_item['parent'], GRAVITY_PARENT];
$total = DBA::count('item', $condition);
$pager = new Pager(DI::l10n(), DI::args()->getQueryString());