[fix] Silence some warnings caused by routine sql query failures.
This commit is contained in:
parent
49f9640450
commit
649ca36f36
1
CHANGES
1
CHANGES
|
@ -49,6 +49,7 @@ v2.38 (Unreleased)
|
|||
[fix] Fix printing on remote hosts with newer CUPS
|
||||
[fix] Respect embedded (and non-sRGB) ICC profiles when printing
|
||||
[misc] Have next/prev photo links remember display size
|
||||
[fix] A few warnings triggered by sql query failures
|
||||
|
||||
v2.37.1 (December 3, 2012)
|
||||
|
||||
|
|
10
src/feed.php
10
src/feed.php
|
@ -135,11 +135,12 @@ case 'photos':
|
|||
}
|
||||
|
||||
$photo_data = get_photo_query($database, array(), $froms, $filter, $offset, $limit, $order);
|
||||
|
||||
if ($photo_data === FALSE) break;
|
||||
|
||||
for ($cell_counter = 0; $cell_counter < sizeof($photo_data); $cell_counter++) {
|
||||
$photo = $photo_data[$offset + $cell_counter];
|
||||
if ($photo == FALSE) break;
|
||||
|
||||
if ($photo === FALSE) break;
|
||||
|
||||
$photo['caption'] = get_photo_title($photo['caption'], $photo['title'], $photo['original_image_name']);
|
||||
|
||||
$item = new FeedItem();
|
||||
|
@ -248,12 +249,13 @@ case 'folder':
|
|||
limit $limit");
|
||||
|
||||
$search_result = pg_fetch_all($search_result);
|
||||
if ($search_result === FALSE) break;
|
||||
|
||||
$args = array();
|
||||
|
||||
for ($i = 0 ; $i < sizeof($search_result); $i++) {
|
||||
$row = $search_result[$offset + $i];
|
||||
if ($row == FALSE) break;
|
||||
if ($row === FALSE) break;
|
||||
|
||||
$item = new FeedItem();
|
||||
$item->title = $row['caption'];
|
||||
|
|
Loading…
Reference in New Issue